Skip to content

Commit 53accba

Browse files
docs: contact page (#606)
Signed-off-by: David Dal Busco <[email protected]>
1 parent ced5980 commit 53accba

File tree

5 files changed

+75
-1
lines changed

5 files changed

+75
-1
lines changed

docusaurus.config.ts

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -194,7 +194,8 @@ const config: Config = {
194194
{ to: "/showcase", label: "Showcase" },
195195
{ to: "/blog", label: "Blog" },
196196
{ to: "/newsletter", label: "Newsletter" },
197-
{ to: "/sponsorship", label: "Sponsorship" }
197+
{ to: "/sponsorship", label: "Sponsorship" },
198+
{ to: "/contact", label: "Contact" }
198199
]
199200
},
200201
{
@@ -329,6 +330,10 @@ const config: Config = {
329330
{
330331
label: "Brand & Press",
331332
href: "https://github.com/junobuild/brand"
333+
},
334+
{
335+
label: "Contact",
336+
to: "/contact"
332337
}
333338
]
334339
}

src/components/Contact/index.tsx

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
import { useEffect, useState } from "react";
2+
import styles from "./styles.module.scss";
3+
4+
export default function Contact(): JSX.Element {
5+
// Do not prerender to prevent spam
6+
// See 2.6 - https://spencermortensen.com/articles/email-obfuscation/
7+
let [loaded, setLoaded] = useState(false);
8+
9+
useEffect(() => {
10+
setLoaded(true);
11+
}, []);
12+
13+
return (
14+
<>
15+
<h2 className={styles.sub}>Contact</h2>
16+
17+
<p>
18+
Have a question or want to get in touch? Send an email to{" "}
19+
{loaded && <a href="mailto:[email protected]">[email protected]</a>}
20+
</p>
21+
22+
<p>
23+
For technical questions, bug reports, or implementation help, the&nbsp;
24+
<a
25+
href="https://discord.gg/wHZ57Z2RAG"
26+
rel="noopener nofollower"
27+
target="_blank"
28+
>
29+
Discord
30+
</a>{" "}
31+
community is the best place to get quick answers from other developers.
32+
</p>
33+
</>
34+
);
35+
}
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
@use "../../mixins/fonts";
2+
3+
.sub {
4+
margin: 1rem 0 0.75rem;
5+
@include fonts.h2;
6+
}
7+
8+
.action {
9+
margin: 0 0 8rem;
10+
}
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
.container {
2+
margin: 3rem auto 12rem;
3+
max-width: var(--ifm-container-width);
4+
padding: 0 var(--ifm-spacing-horizontal);
5+
width: 100%;
6+
}

src/pages/contact/index.tsx

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
import Contact from "@site/src/components/Contact";
2+
import Head from "@site/src/components/Head";
3+
import Layout from "@theme/Layout";
4+
import styles from "./index.module.scss";
5+
6+
export default function ContactPage(): JSX.Element {
7+
return (
8+
<Layout>
9+
<Head>
10+
<link href="https://juno.build/newsletter" rel="canonical" />
11+
</Head>
12+
13+
<section className={styles.container}>
14+
<Contact />
15+
</section>
16+
</Layout>
17+
);
18+
}

0 commit comments

Comments
 (0)