From ee5805434deb7ec047c3b931f0e50945494912ca Mon Sep 17 00:00:00 2001 From: Amira24523 <85802878+Amira24523@users.noreply.github.com> Date: Wed, 21 Jun 2023 22:32:57 +0200 Subject: [PATCH] StatusBar Color update --- anwendung/src/components/StatusBar.jsx | 22 +++++++++++++++++----- anwendung/src/styles/globals.css | 10 ++-------- 2 files changed, 19 insertions(+), 13 deletions(-) diff --git a/anwendung/src/components/StatusBar.jsx b/anwendung/src/components/StatusBar.jsx index 37b1ac9..b166a0e 100644 --- a/anwendung/src/components/StatusBar.jsx +++ b/anwendung/src/components/StatusBar.jsx @@ -5,18 +5,30 @@ import {console} from "next/dist/compiled/@edge-runtime/primitives/console"; export default function StatusBar(p) { if(p.progress > 100) p.progress = 100; - let classNames = ["not-started", "started", "finished"]; + let classNames = ["not-started"]; let index = p.progress / 50; + let index2 = p.progress / 100; + let index3 = p.progress - 100; + let index4 = p.progress - 50; - let actives = ["", "", ""] + let actives = ["", "", ""]; actives[index] = "active"; + let actives2 = ["", "", ""]; + actives2[index2] = "finished"; + + let actives3 = ["", "", ""]; + actives3[index3] = "finished"; + + let actives4 = ["", "", ""]; + actives4[index4] = "finished"; + return (