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
Revamp dashboard UI and metrics graph, add animated star
Juan Denis30abb2fdfa9f
diff --git a/frontend/src/assets/ServerKitLogo.svg b/frontend/src/assets/ServerKitLogo.svgindex bd8461b4..2cdd0b69 100644--- a/frontend/src/assets/ServerKitLogo.svg+++ b/frontend/src/assets/ServerKitLogo.svg@@ -6,6 +6,8 @@<stop offset="100%" stop-color="#4f46e5"/></linearGradient></defs>+ <!-- White background matching the outer shape -->+ <rect x="150" y="150" width="1748" height="1748" rx="150" fill="white"/><path fill="url(#brandGradient)" d="M169.61,1878.37c-58.74-56.76-93.82-135.58-99.4-217.52l.07-1284.1C80.47,209.28,209.08,77.66,377.92,70.27l1289.92-.07c173.25,6.73,300.76,139.7,309.9,311.19l.06,1279.44c-10.02,173.54-152.93,308.11-325.14,316.88l-1255.02.07c-87.51-5.09-165.43-38.95-228.02-99.43ZM1600.9,819.3v-69.2l1.69-1.47c59.31,8.75,119.93-21.99,131.77-83.73-.72-71.44,5.91-148.48,1.5-219.58-3.43-55.29-41.89-95.55-97.11-100.61-413.15,1.13-826.62-1.98-1239.58,1.56-51.76,10.06-83.97,47.53-87.04,100.22-3.95,67.93,2.93,139.76.2,208.09,4.42,37.49,26.63,70.13,61.53,85.02,23.73,10.12,47.78,10.56,73.24,9.92v68.04l-1.74,1.74h-40.71c-45.8,0-92.81,51.61-92.51,97.07,3.38,69-4.35,142.03.06,210.56,3.45,53.53,45.33,92.53,98.22,96.01,9.99.66,24.77-1.69,33.78-.05,1.3.24,2.18.59,2.91,1.74v68.04c-24.94.44-50.51-.87-73.69,9.47-33.62,15-57.82,47.15-61.08,84.31-5.99,68.38,4.22,144.71-.21,213.92,3.28,52.32,44.65,90.9,95.96,95.95h1229.5c51.94-2.48,94.76-42.48,98.27-94.8,4.66-69.44-3.58-144.06-.06-214.04-3.42-45.19-36.88-83.18-81.39-91.91-17.66-3.46-35.59-3-53.51-2.9v-69.79c25.25-.07,50.09,2.08,73.69-8.31,33.21-14.62,58.51-47.53,61.21-84.17,5.14-69.51-3.85-145.06.06-215.21.59-44-45.85-95.91-90.19-95.91h-44.78Z"/><path fill="url(#brandGradient)" d="M1645.86,904.61c3.93,3.68,5.98,9.92,6.26,15.26l-.03,202.43c-1.99,12.99-7.56,18.2-20.23,20.58-366.99.71-735.14,1.01-1102.74.1-34.1-.08-74.96,3.4-108.21.86-12.89-.98-23.01-8.16-24.86-21.66-3.47-25.29,2.96-56.74-.82-82.67,4.31-38.56-3.36-82.85.71-120.78,1.27-11.82,9.02-18.56,20.49-20.22l1209.55-.18c6.82.6,14.7,1.41,19.9,6.28ZM1209.84,975.47c-55.44,6.6-51.14,94.89,7.75,93.93,63.57-1.04,59.56-101.94-7.75-93.93ZM1365.67,975.45c-61.66,8.44-45.2,107.48,17.76,92.2,56.18-13.63,41.64-100.33-17.76-92.2ZM1496.63,1056.16c43.4,42.6,108.56-24.61,64.2-68.27-43.1-42.42-108.68,24.61-64.2,68.27Z"/><path fill="url(#brandGradient)" d="M415.4,1373.21l1215.01-.13c25.54,2.02,22.46,28.97,22.91,48.11,1.15,49.88,1.8,107.07-.04,157.09-.77,21.02-.79,36.94-26.17,38.94l-1211.71-.32c-7.31-1.22-17.24-9.74-19.19-16.87-2.27-69.63-2.66-140.15.23-209.73,2.3-9.69,9.95-14.4,18.96-17.1ZM1250.4,1462.9c-43.81-44.48-111.6,23.9-65.76,67.51,43.96,41.83,107.52-25.1,65.76-67.51ZM1528.49,1449.01c-62.25,2.08-59.67,94.67.89,93.82,62.28-.87,57.86-95.78-.89-93.82ZM1405.09,1529.54c43.25-43.24-20.92-110.55-65.3-67.04-43.23,42.39,21.83,110.51,65.3,67.04Z"/>diff --git a/frontend/src/components/MetricsGraph.jsx b/frontend/src/components/MetricsGraph.jsxindex 9fa3c27a..f2beceba 100644--- a/frontend/src/components/MetricsGraph.jsx+++ b/frontend/src/components/MetricsGraph.jsx@@ -1,19 +1,19 @@-import React, { useState, useEffect } from 'react';+import React, { useState, useEffect, useMemo } from 'react';import {XAxis, YAxis, CartesianGrid,Tooltip, ResponsiveContainer, Area, AreaChart} from 'recharts';-import { Cpu, MemoryStick, HardDrive, TrendingUp, Wifi } from 'lucide-react';+import { Cpu, MemoryStick, HardDrive, TrendingUp } from 'lucide-react';import api from '../services/api';// Chart colors - matching new_dashboard_3 styleconst CHART_COLORS = {- cpu: '#6366f1', // Purple/Indigo (CPU Core)- memory: '#10b981', // Green (Memory)- network: '#f59e0b' // Amber/Orange (Network)+ cpu: '#6366f1', // Purple/Indigo+ memory: '#10b981', // Green (RAM)+ disk: '#f59e0b' // Amber/Orange (Disk)};-const MetricsGraph = ({ compact = false }) => {+const MetricsGraph = ({ compact = false, timezone }) => {const [data, setData] = useState(null);const [period, setPeriod] = useState('1h');const [loading, setLoading] = useState(true);@@ -21,7 +21,7 @@ const MetricsGraph = ({ compact = false }) => {const [visibleMetrics, setVisibleMetrics] = useState({cpu: true,memory: true,- network: true+ disk: true});const periods = ['1h', '6h', '24h', '7d', '30d'];@@ -52,17 +52,49 @@ const MetricsGraph = ({ compact = false }) => {function formatTimestamp(isoString) {const date = new Date(isoString);- if (period === '1h' || period === '6h') {- return date.toLocaleTimeString([], { hour: '2-digit', minute: '2-digit' });- } else if (period === '24h') {- return date.toLocaleTimeString([], { hour: '2-digit', minute: '2-digit' });+ const tz = timezone || undefined;+ if (period === '1h' || period === '6h' || period === '24h') {+ return date.toLocaleTimeString([], { hour: '2-digit', minute: '2-digit', timeZone: tz });} else if (period === '7d') {- return date.toLocaleDateString([], { weekday: 'short', hour: '2-digit' });+ return date.toLocaleDateString([], { weekday: 'short', hour: '2-digit', timeZone: tz });} else {- return date.toLocaleDateString([], { month: 'short', day: 'numeric' });+ return date.toLocaleDateString([], { month: 'short', day: 'numeric', timeZone: tz });}}+ const chartData = data?.data?.map(point => ({+ time: formatTimestamp(point.timestamp),+ cpu: point.cpu.percent,+ memory: point.memory.percent,+ disk: point.disk.percent+ })) || [];++ // Auto-zoom: compute Y-axis ceiling from visible metrics+ const yDomain = useMemo(() => {+ if (chartData.length === 0) return [0, 100];++ const activeKeys = Object.entries(visibleMetrics)+ .filter(([, visible]) => visible)+ .map(([key]) => key);++ if (activeKeys.length === 0) return [0, 100];++ let maxVal = 0;+ chartData.forEach(point => {+ activeKeys.forEach(key => {+ if (point[key] > maxVal) maxVal = point[key];+ });+ });++ // Add 20% headroom, floor at 10%+ const ceiling = Math.max(10, maxVal * 1.2);+ // Snap to nearest nice tick value+ const steps = [5, 10, 15, 20, 25, 30, 40, 50, 60, 75, 100];+ const niceMax = steps.find(s => s >= ceiling) || 100;++ return [0, niceMax];+ }, [chartData, visibleMetrics]);+if (loading && !data) {return (<div className="metrics-graph-card loading">@@ -89,13 +121,6 @@ const MetricsGraph = ({ compact = false }) => {);}- const chartData = data.data.map(point => ({- time: formatTimestamp(point.timestamp),- cpu: point.cpu.percent,- memory: point.memory.percent,- network: point.disk.percent // Using disk data for network display- }));-const CustomTooltip = ({ active, payload, label }) => {if (active && payload && payload.length) {return (@@ -167,7 +192,7 @@ const MetricsGraph = ({ compact = false }) => {<span>{data.summary.memory_avg}%</span></div><div className="summary-item">- <Wifi size={14} />+ <HardDrive size={14} /><span>{data.summary.disk_avg}%</span></div></div>@@ -186,19 +211,19 @@ const MetricsGraph = ({ compact = false }) => {className={`filter-btn cpu ${visibleMetrics.cpu ? 'active' : ''}`}onClick={() => toggleMetric('cpu')}>- CPU Core+ CPU</button><buttonclassName={`filter-btn memory ${visibleMetrics.memory ? 'active' : ''}`}onClick={() => toggleMetric('memory')}>- Memory+ RAM</button><button- className={`filter-btn network ${visibleMetrics.network ? 'active' : ''}`}- onClick={() => toggleMetric('network')}+ className={`filter-btn disk ${visibleMetrics.disk ? 'active' : ''}`}+ onClick={() => toggleMetric('disk')}>- Network+ Disk</button></div><div className="period-selector">@@ -215,7 +240,7 @@ const MetricsGraph = ({ compact = false }) => {</div><div className="metrics-chart-container">- <ResponsiveContainer width="100%" height={280}>+ <ResponsiveContainer width="100%" height={420}><AreaChart data={chartData} margin={{ top: 10, right: 10, left: -10, bottom: 0 }}><defs>{/* CPU Gradient - Purple/Indigo */}@@ -228,10 +253,10 @@ const MetricsGraph = ({ compact = false }) => {<stop offset="5%" stopColor={CHART_COLORS.memory} stopOpacity={0.5} /><stop offset="95%" stopColor={CHART_COLORS.memory} stopOpacity={0} /></linearGradient>- {/* Network Gradient - Orange */}- <linearGradient id="networkGradient" x1="0" y1="0" x2="0" y2="1">- <stop offset="5%" stopColor={CHART_COLORS.network} stopOpacity={0.5} />- <stop offset="95%" stopColor={CHART_COLORS.network} stopOpacity={0} />+ {/* Disk Gradient - Orange */}+ <linearGradient id="diskGradient" x1="0" y1="0" x2="0" y2="1">+ <stop offset="5%" stopColor={CHART_COLORS.disk} stopOpacity={0.5} />+ <stop offset="95%" stopColor={CHART_COLORS.disk} stopOpacity={0} /></linearGradient></defs><CartesianGrid strokeDasharray="3 3" stroke="#27272a" opacity={0.5} />@@ -243,7 +268,7 @@ const MetricsGraph = ({ compact = false }) => {interval="preserveStartEnd"/><YAxis- domain={[0, 100]}+ domain={yDomain}tick={{ fontSize: 11, fill: '#a1a1aa' }}axisLine={{ stroke: '#27272a' }}tickLine={false}@@ -252,35 +277,35 @@ const MetricsGraph = ({ compact = false }) => {<Tooltip content={<CustomTooltip />} />{visibleMetrics.cpu && (<Area- type="monotone"+ type="stepAfter"dataKey="cpu"stroke={CHART_COLORS.cpu}fill="url(#cpuGradient)"- strokeWidth={2}+ strokeWidth={1.5}dot={false}name="CPU"/>)}{visibleMetrics.memory && (<Area- type="monotone"+ type="stepAfter"dataKey="memory"stroke={CHART_COLORS.memory}fill="url(#memoryGradient)"- strokeWidth={2}+ strokeWidth={1.5}dot={false}- name="Memory"+ name="RAM"/>)}- {visibleMetrics.network && (+ {visibleMetrics.disk && (<Area- type="monotone"- dataKey="network"- stroke={CHART_COLORS.network}- fill="url(#networkGradient)"- strokeWidth={2}+ type="stepAfter"+ dataKey="disk"+ stroke={CHART_COLORS.disk}+ fill="url(#diskGradient)"+ strokeWidth={1.5}dot={false}- name="Network"+ name="Disk"/>)}</AreaChart>diff --git a/frontend/src/components/Sidebar.jsx b/frontend/src/components/Sidebar.jsxindex d6c0c0a6..045db719 100644--- a/frontend/src/components/Sidebar.jsx+++ b/frontend/src/components/Sidebar.jsx@@ -1,19 +1,72 @@-import React from 'react';+import React, { useState, useEffect } from 'react';import { NavLink } from 'react-router-dom';import { useAuth } from '../contexts/AuthContext';-import { Github, Star } from 'lucide-react';+import { Star } from 'lucide-react';import ServerKitLogo from '../assets/ServerKitLogo.svg';const Sidebar = () => {const { user, logout } = useAuth();+ const [starAnimating, setStarAnimating] = useState(false);++ useEffect(() => {+ let playCount = 0;+ let timeoutId;++ const triggerAnimation = () => {+ setStarAnimating(true);+ setTimeout(() => setStarAnimating(false), 1500);+ playCount++;+ };++ const scheduleNext = () => {+ // Each time it plays, the next interval gets longer+ // 1st: 8-11 min, 2nd: 16-22 min, 3rd: 24-33 min, etc.+ const multiplier = playCount + 1;+ const minMinutes = 8 * multiplier;+ const maxMinutes = 11 * multiplier;+ const delay = (Math.random() * (maxMinutes - minMinutes) + minMinutes) * 60 * 1000;++ timeoutId = setTimeout(() => {+ triggerAnimation();+ scheduleNext();+ }, delay);+ };++ // First play after 1 minute+ const initialDelay = setTimeout(() => {+ triggerAnimation();+ scheduleNext();+ }, 60000);++ return () => {+ clearTimeout(initialDelay);+ clearTimeout(timeoutId);+ };+ }, []);return (<aside className="sidebar"><div className="brand-section"><div className="brand-logo">- <img src={ServerKitLogo} alt="ServerKit" width="28" height="28" />+ <img src={ServerKitLogo} alt="ServerKit" width="42" height="42" /></div><span className="brand-text">ServerKit</span>+ <a+ href="https://github.com/jhd3197/ServerKit"+ target="_blank"+ rel="noopener noreferrer"+ className={`brand-star ${starAnimating ? 'animating' : ''}`}+ title="Star on GitHub"+ >+ <Star size={14} />+ <span className="star-particles">+ <span></span><span></span><span></span><span></span><span></span><span></span>+ </span>+ <span className="star-ring"></span>+ <span className="star-ring ring-2"></span>+ <span className="star-ring ring-3"></span>+ <span className="star-tooltip">Star us!</span>+ </a></div><div className="nav-scroll">@@ -192,19 +245,6 @@ const Sidebar = () => {</div><div className="sidebar-footer">- <a- href="https://github.com/jhd3197/ServerKit"- target="_blank"- rel="noopener noreferrer"- className="promo-btn"- >- <span className="promo-content">- <Github size={14} />- ServerKit- </span>- <span className="promo-tag"><Star size={12} /></span>- </a>-<div className="user-mini" onClick={logout} title="Click to logout"><div className="user-avatar">{user?.username?.charAt(0).toUpperCase() || 'U'}diff --git a/frontend/src/pages/Dashboard.jsx b/frontend/src/pages/Dashboard.jsxindex ed5da73e..f1799f41 100644--- a/frontend/src/pages/Dashboard.jsx+++ b/frontend/src/pages/Dashboard.jsx@@ -31,6 +31,52 @@ const Dashboard = () => {return saved ? parseInt(saved, 10) : 10; // Default 10 seconds});const [lastUpdate, setLastUpdate] = useState(Date.now());+ const [localUptime, setLocalUptime] = useState(null);+ const [localTime, setLocalTime] = useState(null);+ const lastServerUptime = React.useRef(null);+ const lastServerTime = React.useRef(null);+ const syncedAt = React.useRef(null);++ // Sync local counters when server data arrives+ useEffect(() => {+ const serverUptime = metrics?.system?.uptime_seconds;+ const serverTimeStr = metrics?.time?.current_time_formatted;+ const serverTzId = metrics?.time?.timezone_id;++ if (serverUptime && serverUptime !== lastServerUptime.current) {+ lastServerUptime.current = serverUptime;+ setLocalUptime(serverUptime);+ syncedAt.current = Date.now();+ }++ if (serverTimeStr && serverTimeStr !== lastServerTime.current) {+ lastServerTime.current = serverTimeStr;+ // Parse server time into a Date object+ try {+ const parsed = new Date(serverTimeStr);+ if (!isNaN(parsed)) {+ setLocalTime(parsed);+ syncedAt.current = Date.now();+ }+ } catch {+ // If parsing fails, try extracting just the time portion+ }+ }+ }, [metrics?.system?.uptime_seconds, metrics?.time?.current_time_formatted]);++ // Tick every second - increment uptime and time locally+ useEffect(() => {+ const tick = setInterval(() => {+ if (localUptime !== null) {+ setLocalUptime(prev => prev + 1);+ }+ if (localTime !== null) {+ setLocalTime(prev => new Date(prev.getTime() + 1000));+ }+ }, 1000);++ return () => clearInterval(tick);+ }, [localUptime !== null, localTime !== null]);// Load initial datauseEffect(() => {@@ -109,14 +155,19 @@ const Dashboard = () => {}}- // Get uptime from metrics.system (updated via WebSocket/polling)- const uptimeFormatted = formatUptime(metrics?.system?.uptime_seconds);+ // Get uptime from local ticking counter (synced with server)+ const uptimeFormatted = formatUptime(localUptime ?? metrics?.system?.uptime_seconds);// Fallback to systemInfo for static data, prefer metrics.system for live dataconst hostname = metrics?.system?.hostname || systemInfo?.hostname || 'server';const kernelVersion = metrics?.system?.kernel || systemInfo?.kernel || '-';const ipAddress = metrics?.system?.ip_address || systemInfo?.ip_address || '-';const serverTime = metrics?.time;+ // Format the local ticking clock+ const displayTime = localTime+ ? localTime.toLocaleTimeString('en-US', { hour12: false })+ : serverTime?.current_time_formatted?.split(' ')[1] || '--:--:--';+if (loading && metricsLoading) {return <div className="loading">Loading dashboard...</div>;}@@ -132,40 +183,37 @@ const Dashboard = () => {</h1><div className="server-details"><span>IP: {ipAddress}</span>+ <span className="detail-separator">|</span><span>KERNEL: {kernelVersion}</span>+ <span className="detail-separator">|</span><span>UPTIME: {uptimeFormatted.days}d {String(uptimeFormatted.hours).padStart(2, '0')}h {String(uptimeFormatted.minutes).padStart(2, '0')}m</span></div></div>- <div className="clock-widget">- <div className="clock-time">- {serverTime?.current_time_formatted?.split(' ')[1] || '--:--:--'}+ <div className="top-bar-right">+ <div className="clock-widget">+ <span className="clock-time">{displayTime}</span>+ <span className="clock-zone">{serverTime?.timezone_id || 'UTC'}</span></div>- <div className="clock-zone">- ZONE: {serverTime?.timezone_id || 'UTC'}+ <div className="refresh-control">+ <button+ className="btn-refresh"+ onClick={() => { refreshMetrics(); loadData(); }}+ title="Refresh now"+ >+ <RefreshCw size={14} />+ </button>+ <select+ value={refreshInterval}+ onChange={(e) => handleRefreshIntervalChange(parseInt(e.target.value, 10))}+ className="refresh-select"+ title="Auto-refresh interval"+ >+ {REFRESH_OPTIONS.map(opt => (+ <option key={opt.value} value={opt.value}>{opt.label}</option>+ ))}+ </select></div></div>- <div className="refresh-control">- <span className={`connection-status ${connected ? 'live' : 'polling'}`}>- {connected ? '● LIVE' : '○ POLL'}- </span>- <select- value={refreshInterval}- onChange={(e) => handleRefreshIntervalChange(parseInt(e.target.value, 10))}- className="refresh-select"- title="Auto-refresh interval"- >- {REFRESH_OPTIONS.map(opt => (- <option key={opt.value} value={opt.value}>{opt.label}</option>- ))}- </select>- <button- className="btn-refresh"- onClick={() => { refreshMetrics(); loadData(); }}- title="Refresh now"- >- <RefreshCw size={14} />- </button>- </div></div>{/* Grid Container */}@@ -173,7 +221,7 @@ const Dashboard = () => {{/* Metric Tiles */}<div className="metric-tile"><div className="tile-head">- <span className="tile-title">Processor Load</span>+ <span className="tile-title">CPU</span><Zap size={16} className="tile-icon cpu" /></div><div className="tile-val">{(metrics?.cpu?.percent || 0).toFixed(1)}%</div>@@ -187,7 +235,7 @@ const Dashboard = () => {<div className="metric-tile"><div className="tile-head">- <span className="tile-title">Memory Allocation</span>+ <span className="tile-title">RAM</span><Database size={16} className="tile-icon memory" /></div><div className="tile-val">{metrics?.memory?.ram?.used_human || '0 GB'}</div>@@ -199,7 +247,7 @@ const Dashboard = () => {<div className="metric-tile"><div className="tile-head">- <span className="tile-title">Network I/O</span>+ <span className="tile-title">Network</span><Activity size={16} className="tile-icon network" /></div><div className="tile-val">@@ -214,7 +262,7 @@ const Dashboard = () => {<div className="metric-tile"><div className="tile-head">- <span className="tile-title">Disk Operations</span>+ <span className="tile-title">Disk</span><HardDrive size={16} className="tile-icon disk" /></div><div className="tile-val">@@ -229,7 +277,7 @@ const Dashboard = () => {{/* Chart Panel */}<div className="chart-panel">- <MetricsGraph />+ <MetricsGraph timezone={serverTime?.timezone_id} /></div>{/* Spec Panel */}diff --git a/frontend/src/pages/Settings.jsx b/frontend/src/pages/Settings.jsxindex 3ba34f33..8db6aaf1 100644--- a/frontend/src/pages/Settings.jsx+++ b/frontend/src/pages/Settings.jsx@@ -4,7 +4,8 @@ import { useTheme } from '../contexts/ThemeContext';import api from '../services/api';import UsersTab from '../components/settings/UsersTab';import AuditLogTab from '../components/settings/AuditLogTab';-import { Github, FileText, HelpCircle, MessageSquare, Bug, Check, Layers, Download, CheckCircle, RefreshCw, ExternalLink, Star, X } from 'lucide-react';+import { Github, FileText, HelpCircle, MessageSquare, Bug, Check, Download, CheckCircle, RefreshCw, ExternalLink, Star, X } from 'lucide-react';+import ServerKitLogo from '../assets/ServerKitLogo.svg';const Settings = () => {const [activeTab, setActiveTab] = useState('profile');@@ -1770,7 +1771,7 @@ const AboutSection = () => {<div className="about-card"><div className="about-logo">- <Layers size={48} strokeWidth={1.5} />+ <img src={ServerKitLogo} alt="ServerKit Logo" width="64" height="64" /></div><h3>ServerKit</h3><p className="version">Version {version}</p>diff --git a/frontend/src/styles/components/_metrics-graph.less b/frontend/src/styles/components/_metrics-graph.lessindex 57dea72b..ae19fdfe 100644--- a/frontend/src/styles/components/_metrics-graph.less+++ b/frontend/src/styles/components/_metrics-graph.less@@ -213,14 +213,7 @@border-color: rgba(16, 185, 129, 0.3);}- // Network - Orange- &.network.active {- background: rgba(245, 158, 11, 0.1);- color: #f59e0b;- border-color: rgba(245, 158, 11, 0.3);- }-- // Legacy disk class for backwards compatibility+ // Disk - Orange&.disk.active {background: rgba(245, 158, 11, 0.1);color: #f59e0b;@@ -283,8 +276,7 @@box-shadow: 0 0 8px rgba(16, 185, 129, 0.5);}- &.disk,- &.network {+ &.disk {background: #f59e0b;box-shadow: 0 0 8px rgba(245, 158, 11, 0.5);}diff --git a/frontend/src/styles/layout/_sidebar.less b/frontend/src/styles/layout/_sidebar.lessindex 26a11679..e6e89aa6 100644--- a/frontend/src/styles/layout/_sidebar.less+++ b/frontend/src/styles/layout/_sidebar.less@@ -23,30 +23,344 @@height: 70px;display: flex;align-items: center;- gap: 12px;+ gap: 10px;margin-bottom: 1rem;padding: 0 0.5rem;flex-shrink: 0;}.brand-logo {- width: 28px;- height: 28px;+ width: 42px;+ height: 42px;display: grid;place-items: center;flex-shrink: 0;+ position: relative;++ // Subtle glow behind logo+ &::before {+ content: '';+ position: absolute;+ inset: -6px;+ background: radial-gradient(circle, rgba(99, 102, 241, 0.35) 0%, transparent 70%);+ border-radius: 14px;+ filter: blur(10px);+ opacity: 0.85;+ z-index: -1;+ }img {width: 100%;height: 100%;+ filter: drop-shadow(0 0 8px rgba(99, 102, 241, 0.4));}}.brand-text {- font-size: 1rem;- font-weight: @font-weight-semibold;+ font-size: 1.15rem;+ font-weight: @font-weight-bold;color: @text-primary;- letter-spacing: -0.01em;+ letter-spacing: -0.02em;+ background: linear-gradient(135deg, @text-primary 0%, #a5b4fc 100%);+ -webkit-background-clip: text;+ -webkit-text-fill-color: transparent;+ background-clip: text;+}++// Star button in brand section+.brand-star {+ margin-left: auto;+ display: flex;+ align-items: center;+ justify-content: center;+ width: 28px;+ height: 28px;+ border-radius: 50%;+ color: @text-tertiary;+ transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);+ position: relative;+ overflow: visible;++ svg {+ position: relative;+ z-index: 2;+ transition: all 0.3s ease;+ }++ .star-particles,+ .star-ring,+ .star-tooltip {+ pointer-events: none;+ position: absolute;+ }++ .star-particles {+ inset: 0;++ span {+ position: absolute;+ width: 4px;+ height: 4px;+ background: #f59e0b;+ border-radius: 50%;+ opacity: 0;+ top: 50%;+ left: 50%;+ }+ }++ .star-ring {+ inset: 0;+ border-radius: 50%;+ border: 2px solid #f59e0b;+ opacity: 0;+ transform: scale(0.8);+ }++ .star-tooltip {+ top: 50%;+ left: calc(100% + 10px);+ transform: translateY(-50%) translateX(-4px);+ background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);+ color: white;+ font-size: 0.65rem;+ font-weight: 600;+ padding: 4px 10px;+ border-radius: 6px;+ white-space: nowrap;+ opacity: 0;+ box-shadow: 0 4px 12px rgba(245, 158, 11, 0.4);++ &::after {+ content: '';+ position: absolute;+ top: 50%;+ left: -4px;+ transform: translateY(-50%);+ border-top: 5px solid transparent;+ border-bottom: 5px solid transparent;+ border-right: 5px solid #d97706;+ }+ }++ &:hover {+ color: #f59e0b;+ background: rgba(245, 158, 11, 0.15);+ transform: scale(1.1);+ box-shadow: 0 0 20px rgba(245, 158, 11, 0.3);+ }++ &:active {+ transform: scale(0.95);+ }++ // Animation state+ &.animating {+ animation: starPop 1.5s cubic-bezier(0.34, 1.56, 0.64, 1);++ svg {+ color: #f59e0b;+ animation: starSpin 1.5s cubic-bezier(0.34, 1.56, 0.64, 1), starGlow 1.5s ease-in-out;+ }++ // Particles explosion+ .star-particles span {+ animation: particleBurst 1s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;++ &:nth-child(1) { --angle: 0deg; --distance: 20px; animation-delay: 0.1s; }+ &:nth-child(2) { --angle: 60deg; --distance: 24px; animation-delay: 0.15s; }+ &:nth-child(3) { --angle: 120deg; --distance: 18px; animation-delay: 0.1s; }+ &:nth-child(4) { --angle: 180deg; --distance: 22px; animation-delay: 0.2s; }+ &:nth-child(5) { --angle: 240deg; --distance: 20px; animation-delay: 0.12s; }+ &:nth-child(6) { --angle: 300deg; --distance: 26px; animation-delay: 0.18s; }+ }++ // Multiple rings+ .star-ring {+ animation: ringExpand 0.8s cubic-bezier(0.22, 1, 0.36, 1) forwards;++ &.ring-2 {+ animation-delay: 0.15s;+ border-color: #fbbf24;+ }++ &.ring-3 {+ animation-delay: 0.3s;+ border-color: #fcd34d;+ border-width: 1px;+ }+ }++ // Tooltip appears+ .star-tooltip {+ animation: tooltipPop 1.5s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;+ }++ // Background flash+ &::before {+ content: '';+ position: absolute;+ inset: -4px;+ border-radius: 50%;+ background: radial-gradient(circle, rgba(245, 158, 11, 0.4) 0%, transparent 70%);+ animation: bgFlash 0.6s ease-out forwards;+ z-index: -1;+ }++ // Shine sweep+ &::after {+ content: '';+ position: absolute;+ top: 0;+ left: -100%;+ width: 200%;+ height: 100%;+ background: linear-gradient(+ 90deg,+ transparent,+ rgba(255, 255, 255, 0.6),+ transparent+ );+ animation: shineSweep 0.5s 0.2s ease-out forwards;+ border-radius: 50%;+ z-index: 3;+ }+ }+}++// Star icon spin+@keyframes starSpin {+ 0% {+ transform: rotate(0deg) scale(1);+ }+ 25% {+ transform: rotate(-15deg) scale(1.2);+ }+ 50% {+ transform: rotate(15deg) scale(1.3);+ }+ 75% {+ transform: rotate(-5deg) scale(1.1);+ }+ 100% {+ transform: rotate(0deg) scale(1);+ }+}++// Smooth bounce pop+@keyframes starPop {+ 0% {+ transform: scale(1);+ }+ 20% {+ transform: scale(1.4);+ }+ 40% {+ transform: scale(1.1);+ }+ 60% {+ transform: scale(1.25);+ }+ 80% {+ transform: scale(1.15);+ }+ 100% {+ transform: scale(1);+ }+}++// Icon glow pulse+@keyframes starGlow {+ 0%, 100% {+ filter: drop-shadow(0 0 2px rgba(245, 158, 11, 0.4));+ }+ 30% {+ filter: drop-shadow(0 0 8px rgba(245, 158, 11, 1))+ drop-shadow(0 0 16px rgba(245, 158, 11, 0.8))+ drop-shadow(0 0 24px rgba(245, 158, 11, 0.4));+ }+ 60% {+ filter: drop-shadow(0 0 6px rgba(245, 158, 11, 0.8));+ }+}++// Particles burst outward+@keyframes particleBurst {+ 0% {+ opacity: 1;+ transform: translate(-50%, -50%) rotate(var(--angle)) translateY(0) scale(1);+ }+ 50% {+ opacity: 1;+ transform: translate(-50%, -50%) rotate(var(--angle)) translateY(calc(var(--distance) * -0.7)) scale(1.2);+ }+ 100% {+ opacity: 0;+ transform: translate(-50%, -50%) rotate(var(--angle)) translateY(calc(var(--distance) * -1)) scale(0);+ }+}++// Ring that expands outward+@keyframes ringExpand {+ 0% {+ transform: scale(0.8);+ opacity: 1;+ }+ 100% {+ transform: scale(2.5);+ opacity: 0;+ }+}++// Tooltip pop in and out+@keyframes tooltipPop {+ 0% {+ opacity: 0;+ transform: translateY(-50%) translateX(-4px) scale(0.8);+ }+ 20% {+ opacity: 1;+ transform: translateY(-50%) translateX(0) scale(1.05);+ }+ 30% {+ transform: translateY(-50%) translateX(0) scale(1);+ }+ 70% {+ opacity: 1;+ transform: translateY(-50%) translateX(0) scale(1);+ }+ 100% {+ opacity: 0;+ transform: translateY(-50%) translateX(4px) scale(0.9);+ }+}++// Background glow flash+@keyframes bgFlash {+ 0% {+ opacity: 0;+ transform: scale(0.5);+ }+ 30% {+ opacity: 1;+ transform: scale(1.5);+ }+ 100% {+ opacity: 0;+ transform: scale(2);+ }+}++// Shine sweep across+@keyframes shineSweep {+ 0% {+ left: -200%;+ opacity: 1;+ }+ 100% {+ left: 100%;+ opacity: 0;+ }}// Scrollable Navigation Container@@ -147,42 +461,6 @@flex-shrink: 0;}-// Promo Button (GitHub Star CTA)-.promo-btn {- display: flex;- align-items: center;- justify-content: space-between;- padding: 0.65rem 0.75rem;- margin-bottom: 0.75rem;- background: @bg-secondary;- border: 1px solid @border-default;- border-radius: @radius-lg;- color: @text-primary;- font-size: 0.75rem;- font-weight: @font-weight-semibold;- text-decoration: none;- transition: all 0.2s ease;-- &:hover {- border-color: @text-tertiary;- transform: translateY(-1px);- }-- .promo-content {- display: flex;- align-items: center;- gap: 8px;- }-}--.promo-tag {- font-size: 0.65rem;- background: rgba(245, 158, 11, 0.1);- color: @warning;- padding: 2px 6px;- border-radius: @radius-sm;- font-weight: @font-weight-bold;-}// User Mini Profile.user-mini {diff --git a/frontend/src/styles/pages/_dashboard.less b/frontend/src/styles/pages/_dashboard.lessindex fd21b1d3..b8c37891 100644--- a/frontend/src/styles/pages/_dashboard.less+++ b/frontend/src/styles/pages/_dashboard.less@@ -13,7 +13,7 @@.top-bar {display: flex;justify-content: space-between;- align-items: flex-end;+ align-items: center;padding-bottom: @space-4;border-bottom: 1px solid @border-subtle;}@@ -42,22 +42,39 @@.server-details {display: flex;- gap: @space-6;+ align-items: center;+ gap: @space-3;margin-top: @space-2;font-size: @font-size-sm;color: @text-tertiary;font-family: @font-mono;++ .detail-separator {+ color: @border-default;+ user-select: none;+ }+}++// Right section: clock + refresh stacked+.top-bar-right {+ display: flex;+ align-items: center;+ gap: @space-5;}.clock-widget {- text-align: right;+ display: flex;+ flex-direction: column;+ align-items: flex-end;}.clock-time {font-family: @font-mono;- font-size: 1.5rem;+ font-size: 1.25rem;font-weight: @font-weight-bold;color: @text-primary;+ letter-spacing: -0.01em;+ font-variant-numeric: tabular-nums;}.clock-zone {@@ -65,7 +82,7 @@font-weight: @font-weight-semibold;font-size: @font-size-xs;text-transform: uppercase;- letter-spacing: 1px;+ letter-spacing: 0.08em;}// --- Grid System ---@@ -425,28 +442,15 @@// --- Refresh Control ---.refresh-control {display: flex;- align-items: center;- gap: @space-3;- margin-left: auto;- padding-left: @space-4;-}--.connection-status {- font-family: @font-mono;- font-size: @font-size-xs;- font-weight: @font-weight-semibold;- letter-spacing: 0.05em;- padding: @space-1 @space-2;- border-radius: @radius-sm;-- &.live {- color: @success;- background: @success-bg;- }+ flex-direction: column;+ align-items: flex-end;+ gap: @space-2;+ padding-left: @space-5;+ border-left: 1px solid @border-subtle;- &.polling {- color: @warning;- background: @warning-bg;+ .refresh-select,+ .btn-refresh {+ width: 100%;}}