dash / index.html
AkashRAK's picture
enhance
7aff2a7 verified
Raw History Blame Contribute Delete
19.2 kB
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Content Service Revenue Dashboard</title>
<script src="https://cdn.tailwindcss.com"></script>
<script src="https://cdn.jsdelivr.net/npm/chart.js"></script>
<script src="https://cdn.jsdelivr.net/npm/feather-icons/dist/feather.min.js"></script>
<script src="https://unpkg.com/feather-icons"></script>
<style>
.card-hover:hover {
transform: translateY(-5px);
box-shadow: 0 10px 20px rgba(0,0,0,0.1);
}
.bg-gradient-primary {
background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}
.bg-gradient-secondary {
background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
}
</style>
</head>
<body class="bg-gray-50">
<nav class="bg-white shadow-md px-6 py-3 fixed w-full top-0 z-10">
<div class="flex justify-between items-center">
<h1 class="text-xl font-bold text-gray-800">Content Service Revenue Dashboard</h1>
<div class="flex space-x-4">
<a href="#" class="px-3 py-2 text-blue-600 font-medium">Dashboard</a>
<a href="reports.html" class="px-3 py-2 text-gray-600 hover:text-blue-600">Reports</a>
<a href="team.html" class="px-3 py-2 text-gray-600 hover:text-blue-600">Team</a>
</div>
</div>
</nav>
<div class="container mx-auto px-4 py-8 mt-16">
<header class="mb-10 flex justify-between items-center">
<div>
<h1 class="text-4xl font-bold text-gray-800 mb-2">Content Service Revenue Dashboard</h1>
<p class="text-gray-600">Visualizing revenue and operational data from April 2024 to August 2025</p>
</div>
<div class="flex space-x-3">
<button class="bg-blue-600 hover:bg-blue-700 text-white px-4 py-2 rounded-lg flex items-center">
<i data-feather="download" class="mr-2"></i> Export
</button>
<button class="bg-white border border-gray-300 hover:bg-gray-50 text-gray-700 px-4 py-2 rounded-lg flex items-center">
<i data-feather="filter" class="mr-2"></i> Filters
</button>
</div>
</header>
<div class="grid grid-cols-1 md:grid-cols-4 gap-6 mb-10">
<div class="bg-gradient-primary rounded-xl shadow-md p-6 card-hover text-white">
<div class="flex items-center justify-between">
<div>
<p class="text-blue-100">Total Revenue (12 Months)</p>
<h3 class="text-3xl font-bold">₹2.46 Cr</h3>
<p class="text-blue-100 mt-2">↑ 18% vs last period</p>
</div>
<div class="bg-white bg-opacity-20 p-3 rounded-full">
<i data-feather="dollar-sign"></i>
</div>
</div>
</div>
<div class="bg-gradient-secondary rounded-xl shadow-md p-6 card-hover text-white">
<div class="flex items-center justify-between">
<div>
<p class="text-pink-100">Highest Revenue Month</p>
<h3 class="text-3xl font-bold">July 2025</h3>
<p class="text-pink-100">₹32.17 L</p>
<p class="text-pink-100 mt-2">New record</p>
</div>
<div class="bg-white bg-opacity-20 p-3 rounded-full">
<i data-feather="award"></i>
</div>
</div>
</div>
<div class="bg-white rounded-xl shadow-md p-6 card-hover">
<div class="flex items-center justify-between">
<div>
<p class="text-gray-500">Average Monthly Revenue</p>
<h3 class="text-3xl font-bold text-gray-800">₹15.56 L</h3>
<p class="text-gray-500">± 12% variance</p>
</div>
<div class="bg-purple-100 p-3 rounded-full">
<i data-feather="bar-chart-2" class="text-purple-600"></i>
</div>
</div>
</div>
<div class="bg-white rounded-xl shadow-md p-6 card-hover">
<div class="flex items-center justify-between">
<div>
<p class="text-gray-500">Active Projects</p>
<h3 class="text-3xl font-bold text-gray-800">34</h3>
<p class="text-gray-500">12 in progress</p>
</div>
<div class="bg-blue-100 p-3 rounded-full">
<i data-feather="file-text" class="text-blue-600"></i>
</div>
</div>
</div>
</div>
<!-- Date Range Selector -->
<div class="mb-8 bg-white rounded-xl shadow-md p-4 flex justify-between items-center">
<h3 class="font-medium text-gray-700">Date Range: Apr 2024 - Aug 2025</h3>
<div class="flex space-x-2">
<select class="border rounded-lg px-3 py-2 text-sm">
<option>Last 12 Months</option>
<option>Last 6 Months</option>
<option>Year to Date</option>
<option>Custom Range</option>
</select>
<button class="bg-blue-600 hover:bg-blue-700 text-white px-4 py-2 rounded-lg text-sm">
Apply
</button>
</div>
</div>
<!-- Revenue Visualizations Section -->
<div class="mb-16">
<h2 class="text-2xl font-bold text-gray-800 mb-6 border-b pb-2">Revenue Analytics</h2>
<div class="grid grid-cols-1 lg:grid-cols-2 gap-8 mb-10">
<div class="bg-white rounded-xl shadow-md p-6 card-hover">
<h3 class="text-xl font-semibold text-gray-800 mb-4">Monthly Revenue by Service (INR in Lakhs)</h3>
<div class="h-80">
<canvas id="monthlyRevenueChart"></canvas>
</div>
</div>
<div class="bg-white rounded-xl shadow-md p-6 card-hover">
<h3 class="text-xl font-semibold text-gray-800 mb-4">Average Revenue By Service Per Month</h3>
<div class="h-80">
<canvas id="serviceContributionChart"></canvas>
</div>
</div>
</div>
<div class="grid grid-cols-1 gap-8 mb-10">
<div class="bg-white rounded-xl shadow-md p-6 card-hover">
<h3 class="text-xl font-semibold text-gray-800 mb-4">Revenue Trend (INR in Lakhs)</h3>
<div class="h-80">
<canvas id="revenueTrendChart"></canvas>
</div>
</div>
</div>
<div class="bg-white rounded-xl shadow-md p-6 card-hover mb-10">
<h3 class="text-xl font-semibold text-gray-800 mb-4">Revenue per Service Over Time (INR in Lakhs)</h3>
<div class="h-96">
<canvas id="stackedRevenueChart"></canvas>
</div>
</div>
</div>
<!-- Operations Section -->
<div class="mb-10">
<h2 class="text-2xl font-bold text-gray-800 mb-6 border-b pb-2">Operational Metrics</h2>
<div class="bg-white rounded-xl shadow-md p-6 card-hover">
<h3 class="text-xl font-semibold text-gray-800 mb-4">Team Performance</h3>
<div class="space-y-6">
<div>
<h4 class="font-medium text-gray-700">Writing Team</h4>
<div class="mt-4 h-48">
<canvas id="onboardingChart"></canvas>
</div>
<script>
const onboardingCtx = document.getElementById('onboardingChart').getContext('2d');
new Chart(onboardingCtx, {
type: 'bar',
data: {
labels: ['Projects Onboarded', 'Projects Completed'],
datasets: [{
label: 'Count',
data: [111, 77],
backgroundColor: [
'rgba(99, 102, 241, 0.7)',
'rgba(16, 185, 129, 0.7)'
],
borderColor: [
'rgba(99, 102, 241, 1)',
'rgba(16, 185, 129, 1)'
],
borderWidth: 1
}]
},
options: {
responsive: true,
maintainAspectRatio: false,
scales: {
y: {
beginAtZero: true
}
}
}
});
</script>
</div>
<div>
<h4 class="font-medium text-gray-700">Average Aging (Days)</h4>
<div class="grid grid-cols-3 gap-4 mt-2">
<div class="bg-purple-50 p-3 rounded-lg">
<p class="text-sm text-purple-600">Ghost Writing</p>
<p class="font-bold">110</p>
</div>
<div class="bg-yellow-50 p-3 rounded-lg">
<p class="text-sm text-yellow-600">Fiction/Memoir</p>
<p class="font-bold">107</p>
</div>
<div class="bg-red-50 p-3 rounded-lg">
<p class="text-sm text-red-600">Dev. Editing</p>
<p class="font-bold">170</p>
</div>
</div>
</div>
<div>
<h4 class="font-medium text-gray-700">Editing Team</h4>
<div class="grid grid-cols-3 gap-4 mt-2">
<div class="bg-indigo-50 p-3 rounded-lg">
<p class="text-sm text-indigo-600">R1 TAT</p>
<p class="font-bold">11 days</p>
</div>
<div class="bg-pink-50 p-3 rounded-lg">
<p class="text-sm text-pink-600">R2 TAT</p>
<p class="font-bold">3 days</p>
</div>
<div class="bg-teal-50 p-3 rounded-lg">
<p class="text-sm text-teal-600">Words/Day</p>
<p class="font-bold">48K</p>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
<script>
feather.replace();
// Monthly Revenue by Service Chart
const monthlyCtx = document.getElementById('monthlyRevenueChart').getContext('2d');
const monthlyRevenueChart = new Chart(monthlyCtx, {
type: 'bar',
data: {
labels: ['Writing', 'Editing', 'Translation', 'Audio', 'Illustration'],
datasets: [{
label: 'Total Revenue (INR Lakhs)',
data: [1589.33, 636.58, 194.31, 183.07, 7.78],
backgroundColor: [
'rgba(99, 102, 241, 0.7)',
'rgba(244, 63, 94, 0.7)',
'rgba(234, 179, 8, 0.7)',
'rgba(16, 185, 129, 0.7)',
'rgba(139, 92, 246, 0.7)'
],
borderColor: [
'rgba(99, 102, 241, 1)',
'rgba(244, 63, 94, 1)',
'rgba(234, 179, 8, 1)',
'rgba(16, 185, 129, 1)',
'rgba(139, 92, 246, 1)'
],
borderWidth: 1
}]
},
options: {
responsive: true,
maintainAspectRatio: false,
scales: {
y: {
beginAtZero: true,
title: {
display: true,
text: 'Revenue (INR Lakhs/Crores)'
}
}
}
}
});
// Average Revenue By Service Per Month Chart
const contributionCtx = document.getElementById('serviceContributionChart').getContext('2d');
const serviceContributionChart = new Chart(contributionCtx, {
type: 'bar',
data: {
labels: ['Writing', 'Editing', 'Translation', 'Audio', 'Illustration'],
datasets: [{
label: 'Average Monthly Revenue (INR Lakhs)',
data: [93.49, 37.45, 11.43, 10.77, 0.46],
backgroundColor: [
'rgba(99, 102, 241, 0.7)',
'rgba(244, 63, 94, 0.7)',
'rgba(234, 179, 8, 0.7)',
'rgba(16, 185, 129, 0.7)',
'rgba(139, 92, 246, 0.7)'
],
borderColor: [
'rgba(99, 102, 241, 1)',
'rgba(244, 63, 94, 1)',
'rgba(234, 179, 8, 1)',
'rgba(16, 185, 129, 1)',
'rgba(139, 92, 246, 1)'
],
borderWidth: 1
}]
},
options: {
responsive: true,
maintainAspectRatio: false,
plugins: {
legend: {
position: 'right',
},
tooltip: {
callbacks: {
label: function(context) {
const label = context.label || '';
const value = context.raw || 0;
const total = context.dataset.data.reduce((a, b) => a + b, 0);
const percentage = Math.round((value / total) * 100);
return `${label}: ₹${value.toLocaleString()}K (${percentage}%)`;
}
}
}
}
}
});
// Revenue Trend Chart
const trendCtx = document.getElementById('revenueTrendChart').getContext('2d');
const revenueTrendChart = new Chart(trendCtx, {
type: 'line',
data: {
labels: [
'Sep 24', 'Oct 24', 'Nov 24', 'Dec 24', 'Jan 25', 'Feb 25',
'Mar 25', 'Apr 25', 'May 25', 'Jun 25', 'Jul 25', 'Aug 25'
],
datasets: [{
label: 'Total Revenue (INR Lakhs)',
data: [28.33, 15.41, 23.32, 15.47, 23.11, 16.85, 16.68, 19.41, 14.18, 19.08, 32.17, 22.33],
fill: false,
borderColor: 'rgba(99, 102, 241, 0.8)',
tension: 0.3,
pointBackgroundColor: 'rgba(99, 102, 241, 1)',
pointRadius: 4
}]
},
options: {
responsive: true,
maintainAspectRatio: false,
scales: {
y: {
beginAtZero: true,
title: {
display: true,
text: 'Revenue (INR Lakhs/Crores)'
}
}
}
}
});
// Stacked Revenue Chart
const stackedCtx = document.getElementById('stackedRevenueChart').getContext('2d');
const stackedRevenueChart = new Chart(stackedCtx, {
type: 'bar',
data: {
labels: [
'Sep 24', 'Oct 24', 'Nov 24', 'Dec 24', 'Jan 25', 'Feb 25',
'Mar 25', 'Apr 25', 'May 25', 'Jun 25', 'Jul 25', 'Aug 25'
],
datasets: [
{
label: 'Writing',
data: [19.22, 9.99, 11.95, 10.11, 15.49, 11.16, 9.62, 12.71, 4.38, 11.11, 21.88, 16.62],
backgroundColor: 'rgba(99, 102, 241, 0.7)',
},
{
label: 'Editing',
data: [4.08, 3.65, 5.67, 4.71, 4.61, 3.53, 4.12, 4.60, 5.67, 6.42, 6.94, 5.28],
backgroundColor: 'rgba(244, 63, 94, 0.7)',
},
{
label: 'Translation',
data: [2.52, 1.77, 4.73, 0.20, 1.42, 1.71, 2.94, 0.83, 1.32, 0.93, 1.74, 0],
backgroundColor: 'rgba(234, 179, 8, 0.7)',
},
{
label: 'Audio',
data: [2.52, 0, 0.98, 0.45, 1.44, 0.45, 0, 1.27, 2.20, 0.40, 1.43, 0.42],
backgroundColor: 'rgba(16, 185, 129, 0.7)',
},
{
label: 'Illustration',
data: [0, 0, 0, 0, 0.15, 0, 0, 0, 0.60, 0.23, 0.18, 0],
backgroundColor: 'rgba(139, 92, 246, 0.7)',
}
]
},
options: {
responsive: true,
maintainAspectRatio: false,
scales: {
x: {
stacked: true,
},
y: {
stacked: true,
beginAtZero: true,
title: {
display: true,
text: 'Revenue (INR Lakhs/Crores)'
}
}
}
}
});
</script>
</body>
</html>