From 34c6d6f5d057169e3385faeba63ba9efa055347d Mon Sep 17 00:00:00 2001 From: zkldi <20380519+zkldi@users.noreply.github.com> Date: Wed, 14 Dec 2022 06:21:06 +0000 Subject: [PATCH] fix: don't show grade/lamp deltas --- client/src/components/user/UGPTStatShowcase.tsx | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/client/src/components/user/UGPTStatShowcase.tsx b/client/src/components/user/UGPTStatShowcase.tsx index 333630e47..696bbcbe9 100644 --- a/client/src/components/user/UGPTStatShowcase.tsx +++ b/client/src/components/user/UGPTStatShowcase.tsx @@ -23,10 +23,10 @@ import { UserDocument, ShowcaseStatDetails, SongDocument, + Playtype, } from "tachi-common"; import { UGPTPreferenceStatsReturn } from "types/api-returns"; import { GamePT, UGPT } from "types/react"; -import { Playtype } from "tachi-common"; import UGPTStatContainer from "./UGPTStatContainer"; import UGPTStatCreator from "./UGPTStatCreator"; @@ -291,11 +291,17 @@ function StatDelta({ colour = "danger"; } + let delta = null; + + // don't bother highlighting grade/lamp deltas, since they're kinda meaningless + if (property === "percent" || property === "score" || property === "playcount") { + delta = ` (${v2 > v1 ? `+${d}` : v2 === v1 ? `±${d}` : d})`; + } + return (