Skip to content

Commit

Permalink
Convert DiscordCTA to ContactUs (#739)
Browse files Browse the repository at this point in the history
  • Loading branch information
NullSoldier authored Oct 29, 2024
1 parent 5192482 commit ee0784b
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 18 deletions.
Original file line number Diff line number Diff line change
@@ -1,20 +1,19 @@
import { Box, Text, Container, ArrowButton, Flex } from "@/lib/ui";
import Link from "next/link";
import { defineMessages, useIntl } from "react-intl";
import { CONSTANTS } from "../../../shared/constants";
import { CONSTANTS } from "../../shared/constants";

const messages = defineMessages({
heading: {
id: "joinCommunity.heading",
defaultMessage: "Join Our Diverse Community",
id: "ContactUs.heading",
defaultMessage: "Want to say hello?",
},
button: {
id: "joinCommunity.button",
defaultMessage: "Dive into Discord",
emailLink: {
id: "ContactUs.contact",
defaultMessage: "Drop us a line",
},
});

export function DiscordCTA() {
export function ContactUs() {
const { formatMessage } = useIntl();
return (
<Box
Expand Down Expand Up @@ -50,20 +49,16 @@ export function DiscordCTA() {
sm: "row",
}}
justifyContent="center"
gap={{
base: 6,
sm: 8,
}}
>
<ArrowButton
as="a"
href={CONSTANTS.SOCIAL_LINKS.discord}
href={`mailto:${CONSTANTS.CONTACT_US_EMAIL}`}
target="_blank"
rel="noreferrer"
size="sm"
colorScheme="white"
>
{formatMessage(messages.button)}
{formatMessage(messages.emailLink)}
</ArrowButton>
</Flex>
</Box>
Expand Down
4 changes: 2 additions & 2 deletions pages/community/foundation/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import {
Text,
chakra,
} from "@/lib/ui";
import { DiscordCTA } from "@/components/Governance/DiscordCTA/DiscordCTA";
import { ContactUs } from "@/components/ContactUs/ContactUs";
import flower from "../../../assets/heroImages/foundation/flower.svg";
import key from "../../../assets/heroImages/foundation/key.svg";
import weather from "../../../assets/heroImages/foundation/weather.svg";
Expand Down Expand Up @@ -222,7 +222,7 @@ export default function Governance() {
}}
/>
</Box>
<DiscordCTA />
<ContactUs />
</Box>
);
}
4 changes: 2 additions & 2 deletions pages/community/governance/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ import {
import Head from "next/head";
import { GovernanceStructure } from "@/components/Governance/GovernanceStructure/GovernanceStructure";
import { GovernanceFAQ } from "@/components/Governance/GovernanceFAQ/GovernanceFAQ";
import { DiscordCTA } from "@/components/Governance/DiscordCTA/DiscordCTA";
import { ContactUs } from "@/components/ContactUs/ContactUs";
import { defineMessages, useIntl } from "react-intl";
import betta from "../../../assets/heroImages/governance/betta.svg";
import angler from "../../../assets/heroImages/governance/angler.svg";
Expand Down Expand Up @@ -147,7 +147,7 @@ export default function Governance() {

<GovernanceStructure />
<GovernanceFAQ />
<DiscordCTA />
<ContactUs />
</Box>
);
}
3 changes: 3 additions & 0 deletions shared/constants.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,11 @@ const SOCIAL_LINKS = {
telegram: "https://t.me/ironfishcryptochat",
};

const CONTACT_US_EMAIL = "[email protected]";

export const CONSTANTS = {
SOCIAL_LINKS,
CONTACT_US_EMAIL,
};

export const GRANTS_FORM_URL =
Expand Down

0 comments on commit ee0784b

Please sign in to comment.