From 8daf35fb35508f7db69af6e533df67ee31035936 Mon Sep 17 00:00:00 2001 From: Ashish Agarwal Date: Wed, 25 Jun 2025 14:14:41 +0530 Subject: [PATCH 1/3] redesign footer --- components/ui/Footer/Content.tsx | 13 ---- components/ui/Footer/FooterInfo.tsx | 22 ------ components/ui/Footer/FooterLinks.tsx | 80 -------------------- components/ui/Footer/Info.tsx | 11 --- components/ui/Footer/Social.tsx | 29 -------- components/ui/Footer/Socials.tsx | 30 -------- components/ui/Footer/index.tsx | 106 ++++++++++++++++++++++++++- 7 files changed, 103 insertions(+), 188 deletions(-) delete mode 100644 components/ui/Footer/Content.tsx delete mode 100644 components/ui/Footer/FooterInfo.tsx delete mode 100644 components/ui/Footer/FooterLinks.tsx delete mode 100644 components/ui/Footer/Info.tsx delete mode 100644 components/ui/Footer/Social.tsx delete mode 100644 components/ui/Footer/Socials.tsx diff --git a/components/ui/Footer/Content.tsx b/components/ui/Footer/Content.tsx deleted file mode 100644 index 5618c7f..0000000 --- a/components/ui/Footer/Content.tsx +++ /dev/null @@ -1,13 +0,0 @@ -import Socials from './Socials'; -import Info from './Info'; - -export default function Content() { - return ( -
-
- - -
-
- ); -} diff --git a/components/ui/Footer/FooterInfo.tsx b/components/ui/Footer/FooterInfo.tsx deleted file mode 100644 index 9ee76db..0000000 --- a/components/ui/Footer/FooterInfo.tsx +++ /dev/null @@ -1,22 +0,0 @@ -import Info from './Info'; -import Socials from './Socials'; - -export default function FooterInfo() { - return ( - <> -
-
- - - Copyright © ItziSpyder & Contributors 2022- - {new Date().getFullYear()} - - - - Copyright © ItziSpyder & Contributors 2022- - {new Date().getFullYear()} - -
- - ); -} diff --git a/components/ui/Footer/FooterLinks.tsx b/components/ui/Footer/FooterLinks.tsx deleted file mode 100644 index 7a96920..0000000 --- a/components/ui/Footer/FooterLinks.tsx +++ /dev/null @@ -1,80 +0,0 @@ -import Link from 'next/link'; -import FooterInfo from './FooterInfo'; - -const footerLinks = [ - { - title: 'Pages', - links: [ - { name: 'Home', url: '/' }, - { name: 'Downloads', url: '/download' }, - { name: 'Gallery', url: '/gallery' }, - { name: 'Other Projects', url: '/projects' }, - { name: 'Help', url: '/help' }, - ], - }, - { - title: 'Resources', - links: [ - { name: 'ClickScript Wiki', url: 'https://bit.ly/ccs-wiki' }, - { name: 'Scripts Archive', url: '/scripts' }, - { name: 'Configs Library', url: '/configs' }, - { name: 'Script Editor', url: '/editor' }, - ], - }, - { - title: 'Community', - links: [ - { name: 'Discord', url: 'https://discord.gg/zg3ge9VTgr' }, - { - name: 'GitHub', - url: 'https://github.com/clickcrystals-development/ClickCrystals', - }, - { name: 'YouTube', url: 'https://www.youtube.com/@itzispyder' }, - ], - }, - { - title: 'Download', - links: [ - { - name: 'PlanetMC', - url: 'https://www.planetminecraft.com/mod/clickcrystal/', - }, - { - name: 'CurseForge', - url: 'https://www.curseforge.com/minecraft/mc-mods/clickcrystals', - }, - { - name: 'GitHub', - url: 'https://github.com/clickcrystals-development/ClickCrystals', - }, - { name: 'Modrinth', url: 'https://modrinth.com/mod/clickcrystals' }, - { name: 'Instant Download', url: '/get' }, - ], - }, -]; - -export default function FooterLinks() { - return ( -
-
-
- {footerLinks.map((section, index) => ( -
-

- {section.title} -

-
    - {section.links.map((link, linkIndex) => ( -
  • - {link.name} -
  • - ))} -
-
- ))} -
-
- -
- ); -} diff --git a/components/ui/Footer/Info.tsx b/components/ui/Footer/Info.tsx deleted file mode 100644 index 19df1a8..0000000 --- a/components/ui/Footer/Info.tsx +++ /dev/null @@ -1,11 +0,0 @@ -import Image from 'next/image'; -import logo from '@/public/cc-full.png'; -import Link from 'next/link'; - -export default function Info() { - return ( - - ClickCrystals - - ); -} diff --git a/components/ui/Footer/Social.tsx b/components/ui/Footer/Social.tsx deleted file mode 100644 index 13413d6..0000000 --- a/components/ui/Footer/Social.tsx +++ /dev/null @@ -1,29 +0,0 @@ -import { IconDefinition } from '@fortawesome/free-solid-svg-icons'; -import { Container } from '../Container'; -import { FontAwesomeIcon } from '@fortawesome/react-fontawesome'; -import Link from 'next/link'; - -type SocialProps = { - icon: IconDefinition; - url: string; - className: string; -}; - -export const Social = ({ icon, url, className }: SocialProps) => { - return ( -
  • - - - - - -
  • - ); -}; diff --git a/components/ui/Footer/Socials.tsx b/components/ui/Footer/Socials.tsx deleted file mode 100644 index 9cf6ddf..0000000 --- a/components/ui/Footer/Socials.tsx +++ /dev/null @@ -1,30 +0,0 @@ -'use client'; - -import { - faDiscord, - faGithub, - faYoutube, -} from '@fortawesome/free-brands-svg-icons'; -import { Social } from './Social'; - -export default function Socials() { - return ( - - ); -} diff --git a/components/ui/Footer/index.tsx b/components/ui/Footer/index.tsx index c3310b3..b16314d 100644 --- a/components/ui/Footer/index.tsx +++ b/components/ui/Footer/index.tsx @@ -1,9 +1,109 @@ -import FooterLinks from './FooterLinks'; +import Link from 'next/link'; +import { FontAwesomeIcon } from '@fortawesome/react-fontawesome'; +import { + faDiscord, + faGithub, + faYoutube, +} from '@fortawesome/free-brands-svg-icons'; +import Image from 'next/image'; export default function Footer() { return ( -
    - +
    +
    +
    + ClickCrystals + + ClickCrystals + +
    +
    + {[ + { + icon: faDiscord, + url: 'https://discord.gg/zg3ge9VTgr', + label: 'Discord', + color: 'blue-600' + }, + { + icon: faYoutube, + url: 'https://www.youtube.com/@itzispyder', + label: 'YouTube', + color: 'red-600' + }, + { + icon: faGithub, + url: 'https://github.com/clickcrystals-development/ClickCrystals', + label: "GitHub", + color: 'slate-800' + } + ].map(({ icon, url, label, color }) => ( + + + + ))} + {[ + { + color: "[#f16436]", + label: "CurseForge", + link: "https://www.curseforge.com/minecraft/mc-mods/clickcrystals", + icon: "/icons/curseforge.svg" + }, + { + color: "[#1f86a0]", + label: "PlanetMC", + link: "https://www.planetminecraft.com/mod/clickcrystal/", + icon: "/icons/planetmc.svg" + }, + { + color: "[#39a822]", + label: "Modrinth", + link: "https://modrinth.com/mod/clickcrystals", + icon: "/icons/modrinth.svg" + } + ].map(({ color, label, link, icon }) => ( + + {label} + + ))} +
    +
    +
    + + Website made by{' '} + + Ashish Agarwal + + + | + + © {new Date().getFullYear()} ClickCrystals. Not affiliated with Mojang or Microsoft. + +
    ); } From 1842929d13d967d417a2a1f445284ff173a08d70 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Wed, 25 Jun 2025 14:15:30 +0000 Subject: [PATCH 2/3] Prettier Format & ESLint --- components/ui/Footer/index.tsx | 45 +++++++++++++++++++--------------- 1 file changed, 25 insertions(+), 20 deletions(-) diff --git a/components/ui/Footer/index.tsx b/components/ui/Footer/index.tsx index b16314d..ba02c6a 100644 --- a/components/ui/Footer/index.tsx +++ b/components/ui/Footer/index.tsx @@ -29,20 +29,20 @@ export default function Footer() { icon: faDiscord, url: 'https://discord.gg/zg3ge9VTgr', label: 'Discord', - color: 'blue-600' + color: 'blue-600', }, { icon: faYoutube, url: 'https://www.youtube.com/@itzispyder', label: 'YouTube', - color: 'red-600' + color: 'red-600', }, { icon: faGithub, url: 'https://github.com/clickcrystals-development/ClickCrystals', - label: "GitHub", - color: 'slate-800' - } + label: 'GitHub', + color: 'slate-800', + }, ].map(({ icon, url, label, color }) => ( ( Website made by{' '} - + Ashish Agarwal | - © {new Date().getFullYear()} ClickCrystals. Not affiliated with Mojang or Microsoft. + © {new Date().getFullYear()} ClickCrystals. Not affiliated with + Mojang or Microsoft.
    From 358087b64c2b18c27a18b269bcdbe243fbf7ef84 Mon Sep 17 00:00:00 2001 From: Ashish Agarwal Date: Mon, 21 Jul 2025 18:51:31 +0000 Subject: [PATCH 3/3] feat: update download versions to include 1.21.7 and 1.21.8 --- components/Sections/download/DownloadTable.tsx | 2 ++ lib/getDownloads.tsx | 2 +- lib/getLatest.ts | 4 ++-- lib/getReleases.tsx | 4 ++++ 4 files changed, 9 insertions(+), 3 deletions(-) diff --git a/components/Sections/download/DownloadTable.tsx b/components/Sections/download/DownloadTable.tsx index 55e1ab6..1914751 100644 --- a/components/Sections/download/DownloadTable.tsx +++ b/components/Sections/download/DownloadTable.tsx @@ -16,6 +16,8 @@ export default function DownloadTable() { useEffect(() => { const versionColumns = [ + { field: '1218', headerName: '1.21.8' }, + { field: '1217', headerName: '1.21.7' }, { field: '1216', headerName: '1.21.6' }, { field: '1215', headerName: '1.21.5' }, { field: '1211', headerName: '1.21.1' }, diff --git a/lib/getDownloads.tsx b/lib/getDownloads.tsx index 41c4f0c..377bbee 100644 --- a/lib/getDownloads.tsx +++ b/lib/getDownloads.tsx @@ -64,7 +64,7 @@ export async function getPlanetMCDownloads(): Promise { ).text(); const downloads = parseInt(downloadText.replace(/,/g, ''), 10); - return Number.isNaN(downloads) ? 10020 : downloads; // hardcoded + return Number.isNaN(downloads) ? 10429 : downloads; // hardcoded } export async function getTotalDownloads(): Promise { diff --git a/lib/getLatest.ts b/lib/getLatest.ts index 141a3be..e76ece4 100644 --- a/lib/getLatest.ts +++ b/lib/getLatest.ts @@ -1,13 +1,13 @@ // Make sure this is the latest supported minecraft version by ClickCrystals // Like 1.21.1, however remove the dots. -const latestMc = '1211'; +const latestMc = '1218'; import { getParsedReleases } from '@/lib/getReleases'; export async function getLatestLink() { try { const resp = await getParsedReleases(); - const link = resp[0][latestMc]; + const link = resp[0]['latestMc']; return link; } catch (err) { diff --git a/lib/getReleases.tsx b/lib/getReleases.tsx index 97127b4..7432cb6 100644 --- a/lib/getReleases.tsx +++ b/lib/getReleases.tsx @@ -1,6 +1,8 @@ 'use server'; type Assets = { + '1218': null | React.ReactElement; + '1217': null | React.ReactElement; '1216': null | React.ReactElement; '1215': null | React.ReactElement; '1211': null | React.ReactElement; @@ -85,6 +87,8 @@ export async function getParsedReleases() { let downloads = 0; let assetsData: Assets = { + '1218': null, + '1217': null, '1216': null, '1215': null, '1211': null,