aboutsummaryrefslogtreecommitdiffstats
path: root/frontend/src
diff options
context:
space:
mode:
Diffstat (limited to 'frontend/src')
-rw-r--r--frontend/src/components/tables/GenericScoreTable.tsx7
-rw-r--r--frontend/src/pages/Score.tsx3
2 files changed, 7 insertions, 3 deletions
diff --git a/frontend/src/components/tables/GenericScoreTable.tsx b/frontend/src/components/tables/GenericScoreTable.tsx
index f82e1ff..3358f8d 100644
--- a/frontend/src/components/tables/GenericScoreTable.tsx
+++ b/frontend/src/components/tables/GenericScoreTable.tsx
@@ -1,6 +1,7 @@
import React from "react";
interface Score {
+ // eslint-disable-next-line @typescript-eslint/no-explicit-any
[key: string]: any;
timestamp: string | number;
}
@@ -70,7 +71,7 @@ const ScoreDisplay: React.FC<ScoreDisplayProps> = ({
"grade",
];
const expandableKeys = ["judgements", "optional"];
-
+ // eslint-disable-next-line @typescript-eslint/no-explicit-any
const formatValue = (value: any, key: string): string => {
if (value === null || value === undefined) return "N/A";
@@ -102,10 +103,11 @@ const ScoreDisplay: React.FC<ScoreDisplayProps> = ({
};
const renderValue = (
+ // eslint-disable-next-line @typescript-eslint/no-explicit-any
value: any,
key: string,
compact: boolean = false,
- ): JSX.Element => {
+ ): React.ReactElement => {
if (value === null || value === undefined)
return <span className="text-slate-500">N/A</span>;
@@ -260,6 +262,7 @@ const ScoreDisplay: React.FC<ScoreDisplayProps> = ({
return (
<div className="grid grid-cols-1 md:grid-cols-2 lg:grid-cols-2 xl:grid-cols-3 gap-6">
{sortedScores.map((score, index) => {
+ // eslint-disable-next-line @typescript-eslint/no-unused-vars
const { primary, mainStats, expandable, others, timestamp } =
getScoreEntries(score);
diff --git a/frontend/src/pages/Score.tsx b/frontend/src/pages/Score.tsx
index e9feecd..a39ce25 100644
--- a/frontend/src/pages/Score.tsx
+++ b/frontend/src/pages/Score.tsx
@@ -11,6 +11,7 @@ type SortDirection = "asc" | "desc";
const Score = () => {
const { user, isLoading, logout } = useAuth();
const navigate = useNavigate();
+ // eslint-disable-next-line @typescript-eslint/no-explicit-any
const [scores, setScores] = useState<any[]>([]);
const [loading, setLoading] = useState(true);
const [currentPage, setCurrentPage] = useState(1);
@@ -31,7 +32,7 @@ const Score = () => {
alert("Network error during logout. Please try again.");
}
};
-
+ // eslint-disable-next-line @typescript-eslint/no-explicit-any
const flattenScoreData = (score: any) => {
const flat = { ...score, ...score.data };
delete flat.data;
send patches to the email below
yukais@pinapelz.com
include the subject [PATCH repo_name]
pinapelz.com
homepage