From 16d47543c4abe30c06734b56ba92e85e907f58ee Mon Sep 17 00:00:00 2001 From: nickofolas Date: Sun, 24 Apr 2022 16:50:51 -0500 Subject: [PATCH] Update Game Timer --- src/Infiltration/ui/Game.tsx | 2 +- src/Infiltration/ui/GameTimer.tsx | 12 +++++++----- 2 files changed, 8 insertions(+), 6 deletions(-) diff --git a/src/Infiltration/ui/Game.tsx b/src/Infiltration/ui/Game.tsx index f9834ba83..22eb08049 100644 --- a/src/Infiltration/ui/Game.tsx +++ b/src/Infiltration/ui/Game.tsx @@ -111,7 +111,7 @@ export function Game(props: IProps): React.ReactElement { stageComponent = setStage(Stage.Minigame)} />; break; case Stage.Minigame: { - const MiniGame = SlashGame; // minigames[gameIds.id]; + const MiniGame = minigames[gameIds.id]; stageComponent = ; break; } diff --git a/src/Infiltration/ui/GameTimer.tsx b/src/Infiltration/ui/GameTimer.tsx index a55ab0587..354973f77 100644 --- a/src/Infiltration/ui/GameTimer.tsx +++ b/src/Infiltration/ui/GameTimer.tsx @@ -1,8 +1,7 @@ -import LinearProgress from "@mui/material/LinearProgress"; import React, { useState, useEffect } from "react"; import withStyles from "@mui/styles/withStyles"; import { Theme } from "@mui/material/styles"; -import Grid from "@mui/material/Grid"; +import { Paper, LinearProgress } from "@mui/material"; import { use } from "../../ui/Context"; import { AugmentationNames } from "../../Augmentation/data/AugmentationNames"; @@ -19,6 +18,7 @@ const TimerProgress = withStyles((theme: Theme) => ({ interface IProps { millis: number; onExpire: () => void; + noPaper?: boolean; } export function GameTimer(props: IProps): React.ReactElement { @@ -42,9 +42,11 @@ export function GameTimer(props: IProps): React.ReactElement { // https://stackoverflow.com/questions/55593367/disable-material-uis-linearprogress-animation // TODO(hydroflame): there's like a bug where it triggers the end before the // bar physically reaches the end - return ( - + return props.noPaper ? ( + + ) : ( + - + ); }