Skip to content
This repository was archived by the owner on Oct 7, 2024. It is now read-only.

Commit

Permalink
fix: refactor discord and partnership card into one component because…
Browse files Browse the repository at this point in the history
… the share the same HTML structure

#108
  • Loading branch information
cmcWebCode40 committed Aug 4, 2022
1 parent 666128a commit 5f89ecc
Show file tree
Hide file tree
Showing 4 changed files with 37 additions and 54 deletions.
19 changes: 19 additions & 0 deletions src/components/cards/CommunityBannerCard.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
import React from "react";
import Link from "@docusaurus/Link";
import styles from "./card.module.css";

const CommunityBannerCard = ({ link, headerTitle, bodyText, icon }) => {
return (
<Link href={link}>
<div className={styles.communityBanner}>
<div>{icon}</div>
<div className={styles.communityBannerContent}>
<h3>{headerTitle}</h3>
<p>{bodyText}</p>
</div>
</div>
</Link>
);
};

export default CommunityBannerCard;
28 changes: 0 additions & 28 deletions src/components/cards/DiscordCard.js

This file was deleted.

21 changes: 0 additions & 21 deletions src/components/cards/PartnershipCard.js

This file was deleted.

23 changes: 18 additions & 5 deletions src/pages/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,17 +4,17 @@ import Layout from "@theme/Layout";
import Link from "@docusaurus/Link";
import BrowserOnly from "@docusaurus/BrowserOnly";
import ExternalLink from "@site/static/img/external-link.svg";
import DiscordLogo from "@site/static/img/discord-logo.svg";
import useDocusaurusContext from "@docusaurus/useDocusaurusContext";
import styles from "./index.module.css";
import ContentCard from "../components/cards/ContentCard";
import DiscordCard from "../components/cards/DiscordCard";
import PartnerShipCard from "../components/cards/PartnershipCard";
import GithubCard from "../components/cards/GithubCard";
import Footer from "../components/Footer";
import ReadDocsIcon from "@site/static/img/read_docs.svg";
import ExploreAPiICon from "@site/static/img/explore_api.svg";
import IntTutorialIcon from "@site/static/img/interactive_tutorial.svg";
import DemosIcon from "@site/static/img/demos.svg";
import CommunityBannerCard from "../components/cards/CommunityBannerCard";

const contentCards = [
{
Expand Down Expand Up @@ -203,9 +203,22 @@ export default function Home() {
</div>
))}
</div>

<DiscordCard />
<PartnerShipCard />
<CommunityBannerCard
link='https://discord.verida.io'
headerTitle='Join our Discord Community'
icon={
<DiscordLogo
className={styles.communityBannerSvg}
title='DiscordLogo'
/>
}
bodyText={`We would love to hear from you! Let us know what you're building or if you need any assistance getting started.`}
/>
<CommunityBannerCard
link='https://www.verida.io/ecosystem#partner'
headerTitle='Verida Early Adopter Program'
bodyText={`Join the growing ecosystem of partners building the future of web3.`}
/>
<div className={styles.githubCardSection}>
<h2>GitHub Repositories</h2>
<p>
Expand Down

0 comments on commit 5f89ecc

Please sign in to comment.