Update pages and data formatting

This commit is contained in:
e26chiu 2022-12-13 21:45:37 -05:00
parent 9f8a06f03f
commit 49378d0249
6 changed files with 57 additions and 30 deletions

View File

@ -35,7 +35,7 @@ export const I1 = [
},
},
{
category: 'Had "friends with benefits"',
category: "Had friends with benefits",
values: {
"Experienced first before university": 12,
"Experienced first during university": 20,
@ -70,7 +70,7 @@ export const I1 = [
},
},
{
category: "Engaged in intercourse with two or more people at the same time",
category: "Had sex with 2+ people at same time",
values: {
"Experienced first before university": 1,
"Experienced first during university": 3,

View File

@ -110,6 +110,7 @@ export default function CoopPage() {
heading="What company did you work for?"
bodyText="There are lots of companies that people have worked at! It just goes to show that the software world is HUGE. Most people have worked at Google, Meta, Jane Street, and HRT!"
align="center"
noBackground
>
<WordCloud
data={C7i}

View File

@ -85,7 +85,11 @@ export default function Demographics() {
heading="What was your high school admissions average?"
bodyText="With a mean average of roughly 95.5%, getting into any of these programs is no easy feat. That makes everyone special from the day they were admitted into the school! :)"
>
<BarGraphVertical data={D5} {...barGraphProps(isMobile, pageWidth)} />
<BarGraphVertical
data={D5}
{...barGraphProps(isMobile, pageWidth)}
lowerLabelDy="0"
/>
</ComponentWrapper>
<ComponentWrapper
@ -142,7 +146,11 @@ export default function Demographics() {
align="left"
noBackground
>
<BarGraphVertical data={D10} {...barGraphProps(isMobile, pageWidth)} />
<BarGraphVertical
data={D10}
{...barGraphProps(isMobile, pageWidth)}
lowerLabelDy="0"
/>
</ComponentWrapper>
<ComponentWrapper

View File

@ -27,7 +27,7 @@ import { useIsMobile } from "utils/isMobile";
import { BarGraphVertical, BarGraphHorizontal } from "@/components/BarGraph";
import { BottomNav } from "@/components/BottomNav";
import { ComponentWrapper } from "@/components/ComponentWrapper";
import { GroupedBarGraphVertical } from "@/components/GroupedBarGraph";
import { GroupedBarGraphVertical, GroupedBarGraphHorizontal } from "@/components/GroupedBarGraph";
import { Header } from "@/components/Header";
import { PieChart } from "@/components/PieChart";
import { QuotationCarousel } from "@/components/QuotationCarousel";
@ -49,9 +49,30 @@ export default function Demographics() {
subtitle="What have people tried/already done during university?👀"
/>
<ComponentWrapper
heading="Which drugs have you tried/used?"
bodyText="A lot of students also experiment with substances during university. However, we can see that most students have not tried drugs that are more harsh than Marijuana, such as nicotine, cigarettes, or mushrooms."
>
<GroupedBarGraphHorizontal
className={styles.barGraphDemo}
data={I2}
barColors={[Color.primaryAccentLight, Color.secondaryAccentLight]}
barHoverColorsMap={{
[Color.primaryAccentLight]: Color.primaryAccent,
[Color.secondaryAccentLight]: Color.secondaryAccent,
}}
width={barGraphWidth(isMobile, pageWidth)}
minWidth={700}
height={DefaultProp.graphHeight}
margin={{ ...barGraphMargin, ...{ left: 200, bottom: 60 } }}
/>
</ComponentWrapper>
<ComponentWrapper
heading="What level of intimacy have you reached?"
bodyText="Undergrad is a time when we are surrounded by mostly people of our age and given more freedom to seek out relationships. This is reflected in our data by how many respondents first experienced different levels of intimacy during university. But, it is also worth noting that a large chunk of people did not respond for all of the intimacy levels, showing how they have not yet reached there or are uncomfortable sharing."
align="center"
noBackground
>
<GroupedBarGraphVertical
className={styles.barGraphDemo}
@ -62,28 +83,12 @@ export default function Demographics() {
[Color.secondaryAccentLight]: Color.secondaryAccent,
}}
width={barGraphWidth(isMobile, pageWidth)}
height={DefaultProp.graphHeight}
margin={{ ...barGraphMargin, ...{ bottom: 100 } }}
/>
</ComponentWrapper>
<ComponentWrapper
heading="Which drugs have you tried/used?"
bodyText="A lot of students also experiment with substances during university. However, we can see that most students have not tried drugs that are more harsh than Marijuana, such as nicotine, cigarettes, or mushrooms."
align="center"
noBackground
>
<GroupedBarGraphVertical
className={styles.barGraphDemo}
data={I2}
barColors={[Color.primaryAccentLight, Color.secondaryAccentLight]}
barHoverColorsMap={{
[Color.primaryAccentLight]: Color.primaryAccent,
[Color.secondaryAccentLight]: Color.secondaryAccent,
}}
width={barGraphWidth(isMobile, pageWidth)}
height={DefaultProp.graphHeight}
margin={{ ...barGraphMargin, ...{ bottom: 60 } }}
height={700}
margin={{ ...barGraphMargin, ...{ bottom: 200 } }}
minWidth={800}
alternatingLabelSpace={40}
widthAlternatingLabel={1000}
lowerLabelDy="100px"
/>
</ComponentWrapper>
@ -147,7 +152,11 @@ export default function Demographics() {
align="right"
noBackground
>
<BarGraphVertical data={I7} {...barGraphProps(isMobile, pageWidth)} />
<BarGraphVertical
data={I7}
{...barGraphProps(isMobile, pageWidth)}
lowerLabelDy="0"
/>
</ComponentWrapper>
<ComponentWrapper
@ -155,7 +164,11 @@ export default function Demographics() {
bodyText="A little less than half of our respondents are in a relationship as of the time they filled out this survey."
align="left"
>
<BarGraphVertical data={I8} {...barGraphProps(isMobile, pageWidth)} />
<BarGraphVertical
data={I8}
{...barGraphProps(isMobile, pageWidth)}
lowerLabelDy="0"
/>
</ComponentWrapper>
<ComponentWrapper

View File

@ -157,7 +157,11 @@ export default function Demographics() {
bodyText="Waterloos campus is surrounded by great food places. We have a plaza filled with restaurants that serve all sorts of food such as Mexican, East Asian, Persian, Indian, etc. Although most students have learned to cook, we still enjoy eating out ever so often."
align="right"
>
<BarGraphVertical data={L11} {...barGraphProps(isMobile, pageWidth)} />
<BarGraphVertical
data={L11}
{...barGraphProps(isMobile, pageWidth)}
lowerLabelDy="0"
/>
</ComponentWrapper>
<ComponentWrapper

View File

@ -38,6 +38,7 @@ export default function Demographics() {
heading="Do you plan on pursuing post-graduate education?"
bodyText="There are a total of 103 respondents. Interestingly, there is a huge number of students not pursuring post-grad learning. Post-graduate education is not necessarly for everyone!"
align="center"
noBackground
>
<div className={styles.graphContainer}>
<PieChart data={P1} {...pieChartProps(isMobile, pageWidth)} />