mirror of
https://github.com/Sendouc/sendou.ink.git
synced 2026-09-30 15:17:43 -05:00
remove utils folder
This commit is contained in:
@@ -11,7 +11,7 @@ import {
|
||||
} from "components/common/Table";
|
||||
import UserAvatar from "components/common/UserAvatar";
|
||||
import { FiCheck } from "react-icons/fi";
|
||||
import { formatUsername } from "utils/strings";
|
||||
import { getFullUsername } from "lib/strings";
|
||||
import { GetVotingSummariesByMonthAndTierData } from "../../services/plusService";
|
||||
|
||||
export interface PlusVotingHistoryPageProps {
|
||||
@@ -62,7 +62,7 @@ const PlusVotingHistoryPage: React.FC<PlusVotingHistoryPageProps> = ({
|
||||
<TableCell>
|
||||
<UserAvatar user={summary.user} />
|
||||
</TableCell>
|
||||
<TableCell>{formatUsername(summary.user)}</TableCell>
|
||||
<TableCell>{getFullUsername(summary.user)}</TableCell>
|
||||
<TableCell
|
||||
color={summary.percentage >= 50 ? "green.500" : "red.500"}
|
||||
>
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import { PlusRegion, Prisma } from "@prisma/client";
|
||||
import prisma from "prisma/client";
|
||||
import { getPercentageFromCounts } from "utils/plus";
|
||||
import { userBasicSelection } from "utils/prisma";
|
||||
import { getPercentageFromCounts } from "lib/plus";
|
||||
import { userBasicSelection } from "lib/prisma";
|
||||
|
||||
export type GetVotingSummariesByMonthAndTierData = Prisma.PromiseReturnType<
|
||||
typeof getVotingSummariesByMonthAndTier
|
||||
|
||||
@@ -1,5 +0,0 @@
|
||||
import { User } from "@prisma/client";
|
||||
|
||||
export const formatUsername = (
|
||||
user: Pick<User, "discriminator" | "username">
|
||||
) => `${user.username}#${user.discriminator}`;
|
||||
Reference in New Issue
Block a user