-
Notifications
You must be signed in to change notification settings - Fork 531
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
5 changed files
with
150 additions
and
45 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,6 @@ | ||
export default { | ||
plugins: { | ||
'tailwindcss/nesting': {}, | ||
tailwindcss: {}, | ||
autoprefixer: {}, | ||
}, | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,22 @@ | ||
import { playerCountAtom } from "@/hooks/playerlist"; | ||
import { useAtomValue } from "jotai"; | ||
import { UsersIcon } from "lucide-react"; | ||
import { useEffect, useRef } from "react"; | ||
|
||
|
||
export default function PlayerlistSummary() { | ||
const playerCount = useAtomValue(playerCountAtom); | ||
const playerCountFormatted = playerCount.toLocaleString("en-US"); | ||
|
||
return ( | ||
<div | ||
className="flex justify-center items-center h-[211px] | ||
text-3xl font-extralight text-center tracking-wider" | ||
> | ||
PLAYERS: {playerCount} | ||
<div className="w-full flex justify-between items-center p-4"> | ||
<div className="w-16 h-16 dark:bg-zinc-600/50 bg-zinc-300/75 rounded-full flex items-center justify-center"> | ||
<UsersIcon className="w-10 h-10 dark:text-zinc-400 text-zinc-500 text-opacity-80 stroke-1" /> | ||
</div> | ||
<div className="flex flex-col items-end"> | ||
<div className="text-4xl font-mono font-extralight">{playerCountFormatted}</div> | ||
<div className="opacity-80 text-lg font-light tracking-wider">Players</div> | ||
</div> | ||
</div> | ||
); | ||
} |