added logs list

This commit is contained in:
Nalvazhuthi
2025-05-02 17:14:36 +05:30
parent 66d8196537
commit 4b7a868d1a
15 changed files with 604 additions and 51 deletions

View File

@@ -8,6 +8,7 @@ import {
PointElement,
} from "chart.js";
import { PowerIcon, ThroughputSummaryIcon } from "../../icons/analysis";
import { getAvatarColor } from "../../../modules/collaboration/functions/getAvatarColor";
ChartJS.register(LineElement, CategoryScale, LinearScale, PointElement);
@@ -142,13 +143,13 @@ const ThroughputSummary = () => {
<div className="progress-wrapper">
{/* Dynamically create progress bars based on shiftUtilization array */}
{shiftUtilization.map((shift) => (
{shiftUtilization.map((shift, index) => (
<div
key={shift.shift}
className={`progress shift-${shift.shift}`}
style={{
width: `${shift.percentage}%`,
backgroundColor: getRandomColor(),
backgroundColor: getAvatarColor(index),
}}
></div>
))}
@@ -156,11 +157,11 @@ const ThroughputSummary = () => {
<div className="progress-indicator">
{/* Dynamically create shift indicators with random colors */}
{shiftUtilization.map((shift) => (
{shiftUtilization.map((shift, index) => (
<div className="shift-wrapper" key={shift.shift}>
<span
className={`indicator shift-${shift.shift}`}
style={{ backgroundColor: getRandomColor() }} // Random color for indicator
style={{ backgroundColor: getAvatarColor(index) }} // Random color for indicator
></span>
<label>Shift {shift.shift}</label>
</div>