diff --git a/bun.lockb b/bun.lockb index 8c04be3..a314c22 100644 Binary files a/bun.lockb and b/bun.lockb differ diff --git a/package.json b/package.json index 7bd55d6..4e80286 100644 --- a/package.json +++ b/package.json @@ -26,7 +26,7 @@ "sharp": "^0.33.5", "tailwind-merge": "^2.5.2", "tailwindcss-animate": "^1.0.7", - "use-tether": "^1.0.0" + "use-tether": "^1.0.2" }, "devDependencies": { "typescript": "^5", diff --git a/src/components/landing/discord-status.tsx b/src/components/landing/discord-status.tsx index 1863041..c877f5f 100644 --- a/src/components/landing/discord-status.tsx +++ b/src/components/landing/discord-status.tsx @@ -1,7 +1,12 @@ "use client"; import { ReactElement, useEffect, useState } from "react"; -import { DiscordUser, SpotifyActivity, useTetherWS } from "use-tether"; +import { + DiscordUser, + SpotifyActivity, + UserBadge, + useTetherWS, +} from "use-tether"; import Image from "next/image"; import { cn, truncateText } from "@/lib/utils"; import SimpleTooltip from "@/components/ui/simple-tooltip"; @@ -15,31 +20,6 @@ const statusColors = { OFFLINE: "bg-zinc-500", }; -const userBadges = { - // Nitro - "https://cdn.discordapp.com/badge-icons/2ba85e8026a8614b640c2837bcdfe21b.png": - { - name: "Nitro Subscriber", - predicate: (discordUser: DiscordUser) => true, // TODO: Add Nitro predicate - }, - - // Early Supporter - "https://cdn.discordapp.com/badge-icons/7060786766c9c840eb3019e725d2b358.png": - { - name: "Early Supporter", - predicate: (discordUser: DiscordUser) => - discordUser.flags.list.includes("EARLY_SUPPORTER"), - }, - - // Active Developer - "https://cdn.discordapp.com/badge-icons/6bdc42827a38498929a4920da12695d9.png": - { - name: "Active Developer", - predicate: (discordUser: DiscordUser) => - discordUser.flags.list.includes("ACTIVE_DEVELOPER"), - }, -}; - const DiscordStatus = (): ReactElement | undefined => { const discordUser: DiscordUser | undefined = useTetherWS("504147739131641857"); @@ -49,14 +29,14 @@ const DiscordStatus = (): ReactElement | undefined => { return (