Skip to content

Commit f0c1b21

Browse files
authored
feat: add a CoC Reporting page (#48)
feat: add a CoC Reporting page Co-authored-by: Sara Vieira <[email protected]>
2 parents dcac181 + 9dbfb51 commit f0c1b21

File tree

10 files changed

+118
-39
lines changed

10 files changed

+118
-39
lines changed

src/components/Thanks.js

Lines changed: 1 addition & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
import React from 'react'
2-
import { Link } from 'gatsby'
32
import styled from 'styled-components'
43

54
const Thanks = styled.ul`
@@ -13,7 +12,7 @@ const Thanks = styled.ul`
1312
}
1413
`
1514

16-
export default ({ thanks, mainOrganizer, site }) => {
15+
export default ({ thanks }) => {
1716
return (
1817
<>
1918
<Thanks>
@@ -25,22 +24,6 @@ export default ({ thanks, mainOrganizer, site }) => {
2524
</li>
2625
))}
2726
</Thanks>
28-
We have a{' '}
29-
<Link state={{ organizer: mainOrganizer, site: site }} to="/code-of-conduct">
30-
Code of Conduct
31-
</Link>
32-
.
33-
<br />
34-
<Link state={{ site: site }} to="/flags">
35-
What's with all the flags?
36-
</Link>
37-
<br />
38-
Follow QueerJS on{' '}
39-
<a href="https://twitter.com/queerjs" title="Follow us on Twitter">
40-
Twitter
41-
</a>
42-
<br />
43-
<br />
4427
</>
4528
)
4629
}

src/components/footer/elements.js

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
import styled from 'styled-components'
2+
3+
export const FooterWrap = styled.div`
4+
bottom: 0;
5+
`

src/components/footer/index.js

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
import React from 'react'
2+
import { Link } from 'gatsby'
3+
import { FooterWrap } from './elements'
4+
5+
const Footer = () => {
6+
const site = {
7+
title: 'QueerJS',
8+
description: 'A meetup for everyone where Queer Speakers take the stage'
9+
}
10+
11+
return (
12+
<FooterWrap>
13+
We have a{' '}
14+
<Link to="/code-of-conduct"> Code of Conduct</Link>
15+
.
16+
<br />
17+
<Link state={{ site: site }} to="/flags">
18+
What's with all the flags?
19+
</Link>
20+
<br />
21+
Follow QueerJS on{' '}
22+
<a href="https://twitter.com/queerjs" title="Follow us on Twitter">
23+
Twitter
24+
</a>
25+
<br />
26+
<br />
27+
</FooterWrap>
28+
)
29+
}
30+
31+
export default Footer

src/components/header/elements.js

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@ import { Link } from 'gatsby'
44
import styled, { css } from 'styled-components'
55

66
export const Nav = styled.nav`
7-
margin: auto;
87
padding: 3em 0 1.5em;
98
@media screen and (max-width: 38em) {
109
padding: 0.5em 0 0;

src/components/layout/elements.js

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,9 @@ export const Wrapper = styled.main`
7070
width: 80%;
7171
max-width: 56em;
7272
margin: auto;
73+
display: grid;
74+
grid-template-rows: auto 1fr 100px;
75+
height: 100%;
7376
`
7477

7578
export const SubWrapper = styled.div``

src/components/layout/index.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@ import React from 'react'
22
import Header from '../header'
33
import { ThemeProvider } from 'styled-components'
44
import { theme, Global, Wrapper, SubWrapper, SideRainbow } from './elements'
5+
import Footer from '../../components/footer'
56

67
const Layout = ({ children, siteTitle }) => (
78
<ThemeProvider theme={theme}>
@@ -11,6 +12,7 @@ const Layout = ({ children, siteTitle }) => (
1112
<Wrapper>
1213
<Header siteTitle={siteTitle} />
1314
<SubWrapper>{children}</SubWrapper>
15+
<Footer/>
1416
</Wrapper>
1517
</>
1618
</ThemeProvider>

src/pages/_main.js

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ import Panel from '../components/Panel'
1010
import Heading from '../components/Heading'
1111

1212
const Main = ({ city, attendees }) => {
13-
const { site, organizers, mainOrganizer, thanks, speakers, sponsors, info } = city
13+
const { site, thanks, speakers, sponsors, info } = city
1414

1515
return (
1616
<Layout>
@@ -54,12 +54,7 @@ const Main = ({ city, attendees }) => {
5454
</section>
5555

5656
<Panel heading={thanks && thanks.length ? 'Special Thanks' : null}>
57-
<Thanks
58-
organizers={organizers}
59-
thanks={thanks || []}
60-
site={site}
61-
mainOrganizer={(mainOrganizer || []).find(o => o.main)}
62-
/>
57+
<Thanks thanks={thanks || []} />
6358
</Panel>
6459
</Layout>
6560
)

src/pages/code-of-conduct.js

Lines changed: 17 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,21 @@
11
import React from 'react'
22
import SEO from '../components/seo'
3+
import { Link } from 'gatsby'
34
import Layout from '../containers/layout'
45
import Panel from '../components/Panel'
56

6-
const CodeOfConduct = ({ location }) => {
7-
const organizer = (location.state || {}).organizer || {
8-
name: 'Sara Vieira',
9-
phoneNumber: '+351 91 7296 830',
10-
11-
twitterHandle: '@NikkitaFTW'
12-
}
7+
const CodeOfConduct = () => {
138
return (
149
<Layout>
1510
<SEO
1611
title="QueerJS - Code Of Conduct"
1712
description="A meetup for everyone where Queer Speakers take the stage"
1813
/>
19-
<main>
14+
<main
15+
css={`
16+
margin-bottom: 40px;
17+
`}
18+
>
2019
<h1 hidden>Welcome to QueerJS</h1>
2120
<Panel heading="Code of Conduct">
2221
<section
@@ -33,7 +32,11 @@ const CodeOfConduct = ({ location }) => {
3332
from all participants to help ensuring a safe environment for everybody.
3433
</p>
3534
<p>
36-
Need Help? Contact {organizer.name} {organizer.phoneNumber}
35+
{' '}
36+
<Link to="/report" title="Code of Conduct">
37+
Report an Issue
38+
</Link>
39+
.
3740
</p>
3841

3942
<h2>The Quick Version</h2>
@@ -74,8 +77,11 @@ const CodeOfConduct = ({ location }) => {
7477
please notify a QueerJS organizer as soon as possible.
7578
</p>
7679
<p>
77-
If you can’t find the organizer, reach out to {organizer.name} at {organizer.email} /{' '}
78-
{organizer.phoneNumber} / {organizer.twitterHandle}
80+
If you can’t find the organizer, please{' '}
81+
<Link to="/report" title="Code of Conduct">
82+
Report an Issue
83+
</Link>
84+
.
7985
</p>
8086
<p>
8187
Conference staff will be happy to help participants and assist those experiencing

src/pages/flags.js

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -58,15 +58,13 @@ const OrganizersPage = ({ location }) => {
5858
</Panel>
5959
</main>
6060
<Thanks
61-
organizers={[]}
6261
thanks={[
6362
{
6463
link: 'https://www.flaticon.com',
6564
name: 'Thank you to flaticon',
6665
reason: 'icons'
6766
}
6867
]}
69-
site={site}
7068
/>
7169
</Layout>
7270
)

src/pages/report.js

Lines changed: 57 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,57 @@
1+
import React from 'react'
2+
import SEO from '../components/seo'
3+
import Layout from '../containers/layout'
4+
import Panel from '../components/Panel'
5+
import { Link } from 'gatsby'
6+
7+
const Report = () => {
8+
const contactInfo = {
9+
10+
twitterHandle: '@QueerJS'
11+
}
12+
13+
return (
14+
<Layout>
15+
<SEO
16+
title="QueerJS - Code Of Conduct"
17+
description="A meetup for everyone where Queer Speakers take the stage"
18+
/>
19+
<main>
20+
<h1 hidden>Welcome to QueerJS</h1>
21+
<Panel heading="Code of Conduct - Report An Issue">
22+
<section
23+
css={`
24+
line-height: 1.5;
25+
`}
26+
>
27+
<p>
28+
We want QueerJS to be a safe and inclusive environment. That’s why we ask our
29+
attendees to follow our{' '}
30+
<Link to="/code-of-conduct" title="Code of Conduct">
31+
Code of Conduct
32+
</Link>
33+
!
34+
</p>
35+
<p>
36+
In the unfortunate case that you see someone violating the code of conduct, here are
37+
some ways you can report it to us:
38+
</p>
39+
<ul>
40+
<li>- Send a DM to {contactInfo.twitterHandle}</li>
41+
<li>
42+
- Let a{' '}
43+
<Link to="/organizers" title="Code of Conduct">
44+
Core Team
45+
</Link>{' '}
46+
organizer know, either in person or via Twitter.
47+
</li>
48+
<li>- Send an email to <a href={`mailto:${contactInfo.email}`}>{contactInfo.email}</a></li>
49+
</ul>
50+
</section>
51+
</Panel>
52+
</main>
53+
</Layout>
54+
)
55+
}
56+
57+
export default Report

0 commit comments

Comments
 (0)