diff --git a/app/(general)/page.tsx b/app/(general)/page.tsx index 2abdab8..542cb0a 100644 --- a/app/(general)/page.tsx +++ b/app/(general)/page.tsx @@ -1,10 +1,10 @@ import Image from "next/image" import Link from "next/link" -import { FaDiscord, FaGithub } from "react-icons/fa" +import { FaDiscord, FaGithub, FaTelegram } from "react-icons/fa" import { LuBook } from "react-icons/lu" import { meatAddress, siteConfig } from "@/config/site" -import { cn } from "@/lib/utils" +import { cn, truncateEthAddress } from "@/lib/utils" import { buttonVariants } from "@/components/ui/button" import { PageHeader, @@ -12,15 +12,21 @@ import { PageHeaderDescription, PageHeaderHeading, } from "@/components/layout/page-header" -import { truncateEthAddress } from "@/lib/utils" +import { CopyButton } from "@/components/shared/copy-button" import { LightDarkImage } from "@/components/shared/light-dark-image" export default function HomePage() { - return (
- + MEAT {siteConfig.description} - Multisig Address: {truncateEthAddress("0x1bcDe1E93eF614461E117a8B07957f3600ACA06E")} + Multisig Address:{" "} + {truncateEthAddress("0x1bcDe1E93eF614461E117a8B07957f3600ACA06E")} - - Joe Logo - Buy - Discord + + + Telegram + + + + + Joe Logo + Buy + - {/* - - - pnpm create turbo-eth@latest - - - */}
) diff --git a/app/dashboard/holders/page.tsx b/app/dashboard/holders/page.tsx index c67c15b..bb039e8 100644 --- a/app/dashboard/holders/page.tsx +++ b/app/dashboard/holders/page.tsx @@ -5,9 +5,16 @@ import { motion } from "framer-motion" import { FADE_DOWN_ANIMATION_VARIANTS } from "@/config/design" import { Card } from "@/components/ui/card" import { meatAddress } from "@/config/site" +import useSWR from "swr" +import RenderName from "@/components/blockchain/render-name" +import { useNetwork } from "wagmi" +import { trimFormattedBalance } from "@/lib/utils" - +const fetcher = (url: string) => fetch(url).then((res) => res.json()) export default function PageDashboardHolders() { + const { chain } = useNetwork() + const endpoint = `https://api.routescan.io/v2/network/mainnet/evm/43114/etherscan/api?module=token&action=tokenholderlist&contractaddress=${meatAddress}&page=1&offset=24&apikey=YourApiKeyToken` + const { data: topHolders } = useSWR(endpoint, fetcher); return ( top holdings


diff --git a/app/dashboard/layout.tsx b/app/dashboard/layout.tsx index 111d3db..cbc8eaa 100644 --- a/app/dashboard/layout.tsx +++ b/app/dashboard/layout.tsx @@ -1,5 +1,5 @@ import Link from "next/link" -import { FaDiscord, FaGithub, FaTwitter } from "react-icons/fa" +import { FaDiscord, FaGithub, FaTwitter, FaTelegram } from "react-icons/fa" import { menuAdmin } from "@/config/menu-admin" import { menuDashboard } from "@/config/menu-dashboard" @@ -45,6 +45,9 @@ export default function DashboardLayout({ children }: DashboardLayoutProps) { + + + diff --git a/app/dashboard/liquidityProviders/page.tsx b/app/dashboard/liquidityProviders/page.tsx index 5269409..8a27694 100644 --- a/app/dashboard/liquidityProviders/page.tsx +++ b/app/dashboard/liquidityProviders/page.tsx @@ -3,10 +3,18 @@ import { motion } from "framer-motion" import { FADE_DOWN_ANIMATION_VARIANTS } from "@/config/design" -import { lpAddress } from "@/config/site" import { Card } from "@/components/ui/card" +import { lpAddress } from "@/config/site" +import useSWR from "swr" +import RenderName from "@/components/blockchain/render-name" +import { useNetwork } from "wagmi" +import { trimFormattedBalance } from "@/lib/utils" +const fetcher = (url: string) => fetch(url).then((res) => res.json()) export default function PageDashboardLPers() { + const { chain } = useNetwork() + const endpoint = `https://api.routescan.io/v2/network/mainnet/evm/43114/etherscan/api?module=token&action=tokenholderlist&contractaddress=${lpAddress}&page=1&offset=25&apikey=YourApiKeyToken` + const { data: topHolders } = useSWR(endpoint, fetcher); return ( - -

Liquidity Providers

+ +

Liquidity Providers

top liquidity providers

-
- {/* {topHolders.map((holder) => ( -
  • + +
      + {Array.isArray(topHolders?.result) && topHolders.result?.map((holder : any) => ( +
    • - {holder.address} + + {trimFormattedBalance(String(Number(holder?.TokenHolderQuantity) / 1e6)?.toString(), 0)} {"MEAT"}
    • - ))} */} - + ))} + +
    +
    + ) } diff --git a/app/dashboard/page.tsx b/app/dashboard/page.tsx index ed43795..d854558 100644 --- a/app/dashboard/page.tsx +++ b/app/dashboard/page.tsx @@ -8,7 +8,7 @@ import { Card } from "@/components/ui/card" const tokenomics = [ "42% LP (12mo lock)", "21% future airdrops, grants, Sausager buybacks, Ferdy integration", - "21% pre-sale", + "21% pre-sale (funded LP)", "10% Sausagers", "4% MEAT devs (6mo linear vest)", "2% Sausagers team", diff --git a/components/layout/footer.tsx b/components/layout/footer.tsx index 15765cb..fc04fd5 100644 --- a/components/layout/footer.tsx +++ b/components/layout/footer.tsx @@ -1,6 +1,6 @@ import { HTMLAttributes } from "react" import Link from "next/link" -import { FaDiscord, FaGithub, FaTwitter } from "react-icons/fa" +import { FaDiscord, FaGithub, FaTelegram, FaTwitter } from "react-icons/fa" import { siteConfig } from "@/config/site" import { cn } from "@/lib/utils" @@ -35,6 +35,9 @@ export function Footer({ className, ...props }: HTMLAttributes) { + + + ) diff --git a/components/providers/root-provider.tsx b/components/providers/root-provider.tsx index a2ea525..58a9f98 100644 --- a/components/providers/root-provider.tsx +++ b/components/providers/root-provider.tsx @@ -6,7 +6,6 @@ import { ThemeProvider } from "next-themes" import { Provider as RWBProvider } from "react-wrap-balancer" import { useIsMounted } from "@/lib/hooks/use-is-mounted" -import HandleWalletEvents from "@/components/blockchain/handle-wallet-events" import { RainbowKit } from "@/components/providers/rainbow-kit" const queryClient = new QueryClient() @@ -26,7 +25,7 @@ export default function RootProvider({ children }: RootProviderProps) { - {children} + {children} diff --git a/config/site.ts b/config/site.ts index f7542ee..54f9f81 100644 --- a/config/site.ts +++ b/config/site.ts @@ -12,6 +12,7 @@ interface SiteConfig { discord: string twitter: string github: string + telegram: string ferdy: string } } @@ -30,6 +31,7 @@ export const siteConfig: SiteConfig = { discord: "https://discord.gg/YuabytkPgU", twitter: "https://twitter.com/sausagers_xyz", github: "https://github.com/MeatDeveloper/meat-page", + telegram: "https://t.me/+nTsLDyk8WEQyYzgx", ferdy: "https://ferdyflip.xyz/referral/sausagers" }, } @@ -40,4 +42,4 @@ export const DEPLOY_URL = export const meatTestAddress = "0x0337781a02948a35d154ae817d24b0f755357024" export const meatAddress = "0x47c3118Ad183712Acd42648e9E522e13690f29a0" -export const lpAddress = "0x4d0e2e3f4ba0e0e5c4e7e0e1f4c1f5c9f5c9f5c9" \ No newline at end of file +export const lpAddress = "0x60b881fa346e52590b1aa11d94a6d9047702c44e" \ No newline at end of file diff --git a/lib/utils/index.ts b/lib/utils/index.ts index d16a0cf..a9d7880 100644 --- a/lib/utils/index.ts +++ b/lib/utils/index.ts @@ -30,7 +30,7 @@ export function trimFormattedBalance( if (!decimal) return integer const trimmedDecimal = decimal.slice(0, decimals) - return `${integer}.${trimmedDecimal}` + return `${integer}${trimmedDecimal ? "." : ""}${trimmedDecimal}` } export function truncateEthAddress(address: string) { diff --git a/package.json b/package.json index a628a61..3af1877 100644 --- a/package.json +++ b/package.json @@ -104,6 +104,7 @@ "react-wrap-balancer": "^0.3.0", "sharp": "^0.32.5", "siwe": "1.1.6", + "swr": "^2.2.4", "tailwind-merge": "^1.10.0", "tailwindcss": "^3.3.3", "tailwindcss-animate": "^1.0.6", diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 4ed85d6..56e85bd 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -209,6 +209,9 @@ dependencies: siwe: specifier: 1.1.6 version: 1.1.6(ethers@5.7.2) + swr: + specifier: ^2.2.4 + version: 2.2.4(react@18.2.0) tailwind-merge: specifier: ^1.10.0 version: 1.10.0 @@ -25455,6 +25458,16 @@ packages: - utf-8-validate dev: false + /swr@2.2.4(react@18.2.0): + resolution: {integrity: sha512-njiZ/4RiIhoOlAaLYDqwz5qH/KZXVilRLvomrx83HjzCWTfa+InyfAjv05PSFxnmLzZkNO9ZfvgoqzAaEI4sGQ==} + peerDependencies: + react: ^16.11.0 || ^17.0.0 || ^18.0.0 + dependencies: + client-only: 0.0.1 + react: 18.2.0 + use-sync-external-store: 1.2.0(react@18.2.0) + dev: false + /symbol-observable@2.0.3: resolution: {integrity: sha512-sQV7phh2WCYAn81oAkakC5qjq2Ml0g8ozqz03wOGnx9dDlG1de6yrF+0RAzSJD8fPUow3PTSMf2SAbOGxb93BA==} engines: {node: '>=0.10'}