diff --git a/sidebarsCommunity.js b/sidebarsCommunity.js index 1d3cff77..3b22d29b 100644 --- a/sidebarsCommunity.js +++ b/sidebarsCommunity.js @@ -1,8 +1,8 @@ -module.exports = { +rts = { sidebarsCommunity: [ { type: "autogenerated", dirName: ".", }, ], -}; \ No newline at end of file +}; diff --git a/src/components/blogCarousel/blogCard.tsx b/src/components/blogCarousel/blogCard.tsx index e1d95edf..e1ba5c96 100644 --- a/src/components/blogCarousel/blogCard.tsx +++ b/src/components/blogCarousel/blogCard.tsx @@ -1,4 +1,5 @@ "use client"; +import * as React from "react"; import { useState } from "react"; import { motion } from "framer-motion"; import Link from "@docusaurus/Link"; @@ -22,69 +23,58 @@ const BlogCard = ({ } return ( - setIsHovered(true)} - onMouseLeave={() => setIsHovered(false)} - className="relative overflow-hidden h-full shadow-2xl border rounded-2xl" - > - setIsHovered(true)} + onMouseLeave={() => setIsHovered(false)} + className="relative overflow-hidden h-full shadow-2xl border border-gray-200 dark:border-gray-700 rounded-2xl transition-all duration-300" > - {/* White shadow animation - Fixed version */} - - - - + {/* Hover shimmer effect */} + - -
- {date} -
-

- {title} -

-
- {content} -
-
-
- -
+ + + + +
+ {date} +
+

+ {title} +

+
+ {content} +
+
+
+ +
); }; diff --git a/src/components/blogCarousel/blogCarousel.tsx b/src/components/blogCarousel/blogCarousel.tsx index 560cc76a..352b151d 100644 --- a/src/components/blogCarousel/blogCarousel.tsx +++ b/src/components/blogCarousel/blogCarousel.tsx @@ -13,7 +13,7 @@ import { Button } from "../ui/button"; import { useEffect, useState } from "react"; import BlogCard from "./blogCard"; import blogs from "../../database/blogs"; -import Autoplay from "embla-carousel-autoplay" +import Autoplay from "embla-carousel-autoplay"; export function BlogCarousel() { const [api, setApi] = useState(); @@ -21,9 +21,7 @@ export function BlogCarousel() { const [count, setCount] = useState(0); useEffect(() => { - if (!api) { - return; - } + if (!api) return; setCount(api.scrollSnapList().length); setCurrent(api.selectedScrollSnap() + 1); @@ -43,16 +41,15 @@ export function BlogCarousel() { loop: true, }} plugins={[ - Autoplay({ - delay: 2000, - }), - ]} + Autoplay({ + delay: 2000, + }), + ]} > - {blogs.map((blog, index) => ( + {blogs.map((blog) => ( ))} + + {/* Carousel controls */}
- +
{Array.from({ length: count }).map((_, index) => (
- +
diff --git a/src/components/faqs/faqs.tsx b/src/components/faqs/faqs.tsx index f6851ce6..0b5f99d7 100644 --- a/src/components/faqs/faqs.tsx +++ b/src/components/faqs/faqs.tsx @@ -1,6 +1,7 @@ import React, { useState } from "react"; import { FiChevronDown } from "react-icons/fi"; import { motion } from "framer-motion"; +import { useColorMode } from "@docusaurus/theme-common"; // Docusaurus theme detection const faqData = [ { @@ -42,13 +43,19 @@ const faqData = [ const FAQs: React.FC = () => { const [activeIndex, setActiveIndex] = useState(null); + const { colorMode } = useColorMode(); + const isDark = colorMode === "dark"; const toggleAccordion = (index: number) => { setActiveIndex(activeIndex === index ? null : index); }; return ( -
+
@@ -56,10 +63,18 @@ const FAQs: React.FC = () => {
FAQs
-

+

Looking for answers?

-

+

Find answers to the most common questions about Recode Hive.

@@ -75,15 +90,19 @@ const FAQs: React.FC = () => { transition={{ duration: 0.3 }} >
{/* Title */} -

{title}

+

+ {title} +

{/* Description */} -

{description}

+

{description}

{/* Profile Section */}
@@ -71,12 +82,14 @@ const TopMateCard: React.FC = ({ className="w-12 h-12 rounded-full object-cover border-2 border-purple-200" />
- Book a slot at + + Book a slot at + topmate.io/{username} @@ -97,4 +110,4 @@ const TopMateCard: React.FC = ({ ); }; -export default TopMateCard; \ No newline at end of file +export default TopMateCard; diff --git a/src/components/topmate/TopMateSection.tsx b/src/components/topmate/TopMateSection.tsx index 9d256cca..eabc0a71 100644 --- a/src/components/topmate/TopMateSection.tsx +++ b/src/components/topmate/TopMateSection.tsx @@ -1,29 +1,39 @@ import React from 'react'; import TopMateCard from './TopMateCard'; +import { useColorMode } from '@docusaurus/theme-common'; const TopMateSection = () => { + const { colorMode } = useColorMode(); // Get current theme: 'light' or 'dark' + const profileData = { title: "1:1 Mentorship Call", description: "Book a slot, Free for Hive Community Members", duration: "30 mins", - profileImage: "/sanjay.png", // Replace with your profile image + profileImage: "/sanjay.png", username: "sanjaykv" }; return (
-
-
-

+
+
+

Book a Session

-

+

Get personalized guidance and feedback through one-on-one sessions

- -
- {/* You can add multiple cards here with different data */} + +
@@ -31,4 +41,4 @@ const TopMateSection = () => { ); }; -export default TopMateSection; \ No newline at end of file +export default TopMateSection; diff --git a/src/css/custom.css b/src/css/custom.css index dc3ef310..710be1fb 100644 --- a/src/css/custom.css +++ b/src/css/custom.css @@ -155,4 +155,30 @@ -webkit-background-clip: text; -webkit-text-fill-color: transparent; color: transparent; -} \ No newline at end of file +} + +/* Light mode background and text fix */ +[data-theme='light'] { + --ifm-background-color: #ffffff; /* white background */ + --ifm-font-color-base: #000000; /* black text */ + background-color: var(--ifm-background-color); + color: var(--ifm-font-color-base); +} + +/* Dark mode overrides (already there, ensure it's working) */ +[data-theme='dark'] { + background-color: #121212; + color: #ffffff; +} +html.theme-light .bg-white { + background-color: #ffffff !important; +} + +html.theme-light .text-black { + color: #000000 !important; +} + +html.theme-light .text-gray-900 { + color: #1a1a1a !important; +} + diff --git a/src/pages/index.tsx b/src/pages/index.tsx index b93e1cdc..99e4793e 100644 --- a/src/pages/index.tsx +++ b/src/pages/index.tsx @@ -16,27 +16,6 @@ import { CommunityStatsProvider } from "../lib/statsProvider"; import { LandingCommunity } from "../components/Community"; import FAQs from "../components/faqs/faqs"; -// function HomepageHeader() { -// const {siteConfig} = useDocusaurusContext(); -// return ( -//
-//
-// -// {siteConfig.title} -// -//

{siteConfig.tagline}

-//
-// -// Docusaurus Tutorial - 5min ⏱️ -// -//
-//
-//
-// ); -// } - export default function Home(): ReactNode { const { siteConfig } = useDocusaurusContext(); return ( @@ -51,46 +30,56 @@ export default function Home(): ReactNode { src="https://cdn.ampproject.org/v0/amp-auto-ads-0.1.js" /> -
-
-
-
-
- -
-
(window.location.href = "https://www.sanjaykv.com/")} - > - recodehive -
-
- -
-
-
- + + {/* ✅ Wrap in solid background to fix light mode */} +
+
+
+
+
+ +
+
-
- + +
(window.location.href = "https://www.sanjaykv.com/")} + > + recodehive +
+ +
+ +
+ +
+
+ +
+
+ +
+
+ +
+ + + +
+ +
+
-
-
- - - -
-
- -
- - -
+ + +
+
); } diff --git a/src/pages/showcase/index.tsx b/src/pages/showcase/index.tsx index 1773bc97..d74ba5c5 100644 --- a/src/pages/showcase/index.tsx +++ b/src/pages/showcase/index.tsx @@ -24,6 +24,7 @@ import { sortedUsers, type User, type TagType,} from '@site/src/data/users'; import FavoriteIcon from '@site/src/components/svgIcons/FavoriteIcon'; +import { useColorMode } from '@docusaurus/theme-common'; const TITLE = 'Recode Hive: Framing all the opensource projects built by our community members'; @@ -440,23 +441,39 @@ function ShowcaseCards() { } export default function Showcase(): JSX.Element { + return ( + + + ); +} + +function ShowcaseContent() { + const { colorMode } = useColorMode(); + const isDark = colorMode === "dark"; + + return ( +