modem-magic-manager / status.html
KK21200211's picture
add more features to this
d289566 verified
<!DOCTYPE html>
<html lang="en" class="dark">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Status | Modem Magic Manager</title>
<link rel="stylesheet" href="style.css">
<script src="https://cdn.tailwindcss.com"></script>
<script src="https://cdn.jsdelivr.net/npm/feather-icons/dist/feather.min.js"></script>
</head>
<body class="bg-gray-100 dark:bg-gray-900 transition-colors duration-300 min-h-screen">
<custom-navbar></custom-navbar>
<main class="container mx-auto px-4 py-8">
<h1 class="text-3xl font-bold text-gray-800 dark:text-white mb-8">Network Status</h1>
<div class="grid grid-cols-1 md:grid-cols-2 gap-6 mb-8">
<div class="bg-white dark:bg-gray-800 rounded-lg shadow-md p-6">
<h2 class="text-xl font-semibold text-gray-800 dark:text-white mb-4">Connection Status</h2>
<div class="flex items-center mb-2">
<div class="w-3 h-3 rounded-full bg-green-500 mr-2 pulse"></div>
<span class="text-gray-700 dark:text-gray-300">Connected</span>
</div>
<div class="grid grid-cols-2 gap-4 mt-4">
<div>
<p class="text-sm text-gray-500 dark:text-gray-400">Download Speed</p>
<p class="text-2xl font-bold text-primary-500">95.2 Mbps</p>
</div>
<div>
<p class="text-sm text-gray-500 dark:text-gray-400">Upload Speed</p>
<p class="text-2xl font-bold text-secondary-500">42.8 Mbps</p>
</div>
<div>
<p class="text-sm text-gray-500 dark:text-gray-400">Latency</p>
<p class="text-2xl font-bold">24 ms</p>
</div>
<div>
<p class="text-sm text-gray-500 dark:text-gray-400">Uptime</p>
<p class="text-2xl font-bold">12d 4h</p>
</div>
</div>
</div>
<div class="bg-white dark:bg-gray-800 rounded-lg shadow-md p-6">
<h2 class="text-xl font-semibold text-gray-800 dark:text-white mb-4">Connected Devices</h2>
<div class="flex justify-between mb-4">
<div>
<p class="text-sm text-gray-500 dark:text-gray-400">Total Devices</p>
<p class="text-2xl font-bold">8</p>
</div>
<div>
<p class="text-sm text-gray-500 dark:text-gray-400">Active Now</p>
<p class="text-2xl font-bold text-green-500">5</p>
</div>
</div>
<div class="h-48" id="deviceChart"></div>
</div>
</div>
<div class="grid grid-cols-1 md:grid-cols-2 gap-6">
<div class="bg-white dark:bg-gray-800 rounded-lg shadow-md p-6">
<h2 class="text-xl font-semibold text-gray-800 dark:text-white mb-4">Data Usage</h2>
<div class="h-64" id="dataUsageChart"></div>
</div>
<div class="bg-white dark:bg-gray-800 rounded-lg shadow-md p-6">
<h2 class="text-xl font-semibold text-gray-800 dark:text-white mb-4">Recent Events</h2>
<div class="space-y-4">
<div class="flex items-start">
<div class="w-2 h-2 rounded-full bg-green-500 mt-2 mr-3"></div>
<div>
<p class="text-gray-800 dark:text-gray-200">New device connected - Smart TV</p>
<p class="text-sm text-gray-500 dark:text-gray-400">2 minutes ago</p>
</div>
</div>
<div class="flex items-start">
<div class="w-2 h-2 rounded-full bg-blue-500 mt-2 mr-3"></div>
<div>
<p class="text-gray-800 dark:text-gray-200">Firmware check completed</p>
<p class="text-sm text-gray-500 dark:text-gray-400">1 hour ago</p>
</div>
</div>
<div class="flex items-start">
<div class="w-2 h-2 rounded-full bg-yellow-500 mt-2 mr-3"></div>
<div>
<p class="text-gray-800 dark:text-gray-200">Connection instability detected</p>
<p class="text-sm text-gray-500 dark:text-gray-400">3 hours ago</p>
</div>
</div>
</div>
</div>
</div>
</main>
<custom-footer></custom-footer>
<script src="components/navbar.js"></script>
<script src="components/footer.js"></script>
<script src="https://cdn.jsdelivr.net/npm/chart.js"></script>
<script src="script.js"></script>
<script>
feather.replace();
// Initialize charts
document.addEventListener('DOMContentLoaded', function() {
// Device Chart
const deviceCtx = document.getElementById('deviceChart').getContext('2d');
new Chart(deviceCtx, {
type: 'doughnut',
data: {
labels: ['Phones', 'Computers', 'IoT', 'Other'],
datasets: [{
data: [3, 2, 2, 1],
backgroundColor: [
'#6366f1',
'#10b981',
'#f59e0b',
'#888888'
],
borderWidth: 0
}]
},
options: {
cutout: '70%',
plugins: {
legend: {
position: 'right'
}
}
}
});
// Data Usage Chart
const dataUsageCtx = document.getElementById('dataUsageChart').getContext('2d');
new Chart(dataUsageCtx, {
type: 'line',
data: {
labels: ['Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat', 'Sun'],
datasets: [
{
label: 'Download',
data: [12, 19, 15, 22, 18, 25, 30],
borderColor: '#6366f1',
backgroundColor: 'rgba(99, 102, 241, 0.1)',
fill: true,
tension: 0.3
},
{
label: 'Upload',
data: [5, 8, 6, 9, 7, 10, 12],
borderColor: '#10b981',
backgroundColor: 'rgba(16, 185, 129, 0.1)',
fill: true,
tension: 0.3
}
]
},
options: {
responsive: true,
plugins: {
legend: {
position: 'top'
}
},
scales: {
y: {
beginAtZero: true,
title: {
display: true,
text: 'GB'
}
}
}
}
});
});
</script>
</body>
</html>