Skip to content

Commit c0e81ae

Browse files
Merge pull request #105 from TreeHacks/treehacks-2023
Treehacks 2023
2 parents f0f55e2 + fab88f8 commit c0e81ae

33 files changed

+1524
-597
lines changed

package-lock.json

Lines changed: 956 additions & 526 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/index.js

Lines changed: 15 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,8 @@ import Projects from "./js/projects.jsx";
99
import Hackpacks from "./js/hackpacks.jsx";
1010
import RoomStatus from "./js/room-status.jsx";
1111
import Apis from "./js/apis/Apis.jsx";
12-
1312
import Challenge from "./js/challenge.jsx";
13+
1414
import "./favicons/favicons";
1515
import "./index.scss";
1616
import {
@@ -21,6 +21,9 @@ import {
2121
} from "react-router-dom";
2222
import Prizes from "./js/prizes/Prizes.jsx";
2323
import Leaderboard from "./js/leaderboard.jsx";
24+
import Maps from "./js/maps/Maps.jsx";
25+
import Top10 from "./js/top10.jsx";
26+
import ScavLocation from "./js/scavLocation.jsx";
2427

2528
const reload = () => window.location.reload();
2629

@@ -52,9 +55,12 @@ class Main extends React.Component {
5255
<Hackpacks />
5356
</div>
5457
</div>
55-
<div id="group">
58+
{/* <div id="group">
5659
<Leaderboard />
57-
</div>
60+
<div id="sidebar">
61+
<Top10 />
62+
</div>
63+
</div> */}
5864
</div>
5965
);
6066
}
@@ -83,14 +89,17 @@ function App() {
8389
from="/faq"
8490
to="https://treehacks.quip.com/FHPoABlrGBLN"
8591
/>
86-
<CustomRedirect
92+
{/* <CustomRedirect
8793
from="/maps"
8894
to="https://treehacks.quip.com/tOUKAghhGiby/Maps-"
89-
/>
95+
/> */}
9096
<CustomRedirect from="/expo" to="https://treehacks.github.io/expo" />
9197
<Route exact path="/" component={Main} />
92-
<Route exact path="/_room/:roomId" component={RoomStatus} />
98+
{/* <Route exact path="/_room/:roomId" component={RoomStatus} /> */}
99+
<Route exact path="/scavhunt/:locationID" component={ScavLocation} />
93100
<Route exact path="/apisresources" component={Apis} />
101+
<Route exact path="/maps" component={Maps} />
102+
<Route exact path="/leaderboard" component={Top10} />
94103
<Route exact path="/prizes" component={Prizes} />
95104
<Route exact path="/challenges/:challengeId" component={Challenge} />
96105
<Route path="/apple-app-site-association" onEnter={reload} />

src/index.scss

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -88,3 +88,4 @@ body {
8888
@import "sass/apis";
8989
@import "sass/challenge";
9090
@import "sass/leaderboard";
91+
@import "sass/maps";

src/js/announcements.jsx

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -7,19 +7,19 @@ class Announcements extends React.Component {
77
super(props);
88

99
this.state = {
10-
announcements: []
10+
announcements: [],
1111
};
1212

1313
this.md = new Remarkable({
1414
breaks: true,
15-
linkify: true
15+
linkify: true,
1616
});
1717
}
1818

1919
componentWillMount() {
2020
fetch("https://root.treehacks.com/api/announcements")
21-
.then(r => r.json())
22-
.then(announcements => {
21+
.then((r) => r.json())
22+
.then((announcements) => {
2323
if (announcements.error) {
2424
throw new Error(JSON.stringify(announcements.error));
2525
}
@@ -30,18 +30,18 @@ class Announcements extends React.Component {
3030
content: this.md
3131
.render(emojify(text, { output: "unicode" }))
3232
.replace(/\s*&lt;!(?:channel|here)&gt;\s*/g, "") // remove @channel
33-
.replace(/&lt;.*?\|(.*?)&gt;/g, "#$1") // reformat slack links
33+
.replace(/&lt;.*?\|(.*?)&gt;/g, "#$1"), // reformat slack links
3434
};
3535
});
3636
this.setState({ announcements });
3737
this.props.setAnnouncementData(announcements);
3838
})
39-
.catch(e => {
39+
.catch((e) => {
4040
let announcements = [
4141
{
4242
content: `Failed to fetch announcements :( ${e}`,
43-
ts: Date.now() / 1000
44-
}
43+
ts: Date.now() / 1000,
44+
},
4545
];
4646
this.setState({ announcements });
4747
this.props.setAnnouncementData(announcements);

src/js/content.json

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -61,6 +61,40 @@
6161
"link": "https://github.com/TreeHacks/hackpack-web-next"
6262
}
6363
],
64+
"preHackathonWorkshops": [
65+
{
66+
"name": "Education Technology with Professor Dan Schwartz",
67+
"link": "https://drive.google.com/file/d/1FvLw7bmcZt64pr3SK0IUZs6vQzqBt4hG/view?usp=sharing"
68+
},
69+
{
70+
"name": "Healthcare and Technology with Dr. Timothy Chou",
71+
"link": "https://stanford.zoom.us/rec/share/dGaRxfSRv0h691Q72tf4WwtJ5ieEfErov_e6FD00-O2iWL-_weuXi3syj8sKWx8J.63k553i3yMCCE_OS"
72+
},
73+
{
74+
"name": "Web Development",
75+
"link": "https://stanford.zoom.us/rec/share/xFJwDSMvMfisALgV3qIy6ZxJD1dUoo-eCFzcJbQpBxgmrswBMyIKazT-WLdLLqYG.0hWMsW9cM7VgPCDk"
76+
},
77+
{
78+
"name": "Web Development Source Code",
79+
"link": "https://github.com/TreeHacks/treehacks-wordle-clone-2023"
80+
},
81+
{
82+
"name": "ZetaChain: What is interoperability? What is an omnichain smart contract?",
83+
"link": "https://stanford.zoom.us/rec/share/-bAuhxxC0zb3dr8KXC_6Z960q3LwZE5WDxqotIs7AoPKmM13rNJh6RBk1vME8hs.GPb_FdsvQPygLmDd"
84+
},
85+
{
86+
"name": "RF Design in Microwave Office",
87+
"link": "https://stanford.zoom.us/rec/share/H3_xJoMCx11ocYB9GX7nWpH2O7z1BZhJrGXh-3anRyZk21wcyMHNZVU31dijKoS1.Jnj4_qom3Jb5RBYR"
88+
},
89+
{
90+
"name": "Android App Development",
91+
"link": "https://stanford.zoom.us/rec/share/WcPLsitD3ePpbM7kPz9KbKp-4PmD6Lbl1zN222Qses2HDOBfYF15Tc36pOvxbnWj.1SzQ4zUEuJPdOuy5"
92+
},
93+
{
94+
"name": "Android App Development Source Code",
95+
"link": "https://github.com/TreeHacks/android-firebase-todo-list-workshop-src-code"
96+
}
97+
],
6498
"projects": [
6599
{
66100
"name": "Healthcare",

src/js/event-schedule.js

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -115,7 +115,6 @@ export default Vue.component("event-schedule", {
115115
)
116116
.then((r) => r.json())
117117
.then((data) => {
118-
console.log(data);
119118
// Schedule shell
120119
var schedule = [
121120
{

src/js/hackpacks.jsx

Lines changed: 17 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,24 +1,35 @@
1-
import React from 'react';
2-
import {hackpacks} from './content.json';
1+
import React from "react";
2+
import { hackpacks, preHackathonWorkshops } from "./content.json";
33

44
function Hackpacks() {
55
var content = [];
66
for (var i = 0; i < hackpacks.length; i++) {
7-
content.push(HackPack(hackpacks[i].name, hackpacks[i].link))
7+
content.push(HackPack(hackpacks[i].name, hackpacks[i].link));
8+
}
9+
10+
var content2 = [];
11+
for (var i = 0; i < preHackathonWorkshops.length; i++) {
12+
content2.push(
13+
HackPack(preHackathonWorkshops[i].name, preHackathonWorkshops[i].link)
14+
);
815
}
916
return (
1017
<div id="hackpacks" className="section">
1118
<h1 className="section-heading">Hackpacks</h1>
1219
<hr />
13-
<div className="container">
14-
{content}
20+
<div className="container">{content}</div>
21+
<br />
22+
<div id="preHackathon">
23+
<h1 className="section-heading">Pre-Hackathon Workshops</h1>
24+
<hr />
25+
<div className="container">{content2}</div>
1526
</div>
1627
</div>
1728
);
1829
}
1930

2031
function HackPack(name, link) {
21-
return(
32+
return (
2233
<a href={link} target="_blank">
2334
<button className="main-button inverted-button">{name}</button>
2435
</a>

src/js/maps/Maps.jsx

Lines changed: 57 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,57 @@
1+
import React, { useEffect, useState } from "react";
2+
import floor1 from "./floor1.png";
3+
import floor2 from "./floor2.png";
4+
import floor3 from "./floor3.png";
5+
import basement from "./basement.png";
6+
7+
export default class extends React.Component {
8+
constructor(props) {
9+
super(props);
10+
11+
this.state = {
12+
tag: null,
13+
searchInput: "",
14+
};
15+
}
16+
17+
componentDidMount() {}
18+
19+
render() {
20+
return (
21+
<div>
22+
<div
23+
style={{ paddingTop: "0px", paddingBottom: "40px" }}
24+
className="prizes"
25+
>
26+
<h1
27+
className="api-title"
28+
style={{ marginTop: "0px", paddingTop: "20px" }}
29+
>
30+
Maps
31+
</h1>
32+
<p>
33+
Take a look at the floor plans for each floor of the Huang Center
34+
</p>
35+
<div id="map">
36+
<div id="floorContainer">
37+
<h3>Basement</h3>
38+
<img src={basement} alt="logo" />
39+
</div>
40+
<div id="floorContainer">
41+
<h3>First Floor</h3>
42+
<img src={floor1} alt="logo" />
43+
</div>
44+
<div id="floorContainer">
45+
<h3>Second Floor</h3>
46+
<img src={floor2} alt="logo" />
47+
</div>
48+
<div id="floorContainer">
49+
<h3>Third Floor</h3>
50+
<img src={floor3} alt="logo" />
51+
</div>
52+
</div>
53+
</div>
54+
</div>
55+
);
56+
}
57+
}

src/js/maps/basement.png

139 KB
Loading

src/js/maps/floor1.png

127 KB
Loading

src/js/maps/floor2.png

108 KB
Loading

src/js/maps/floor3.png

105 KB
Loading

0 commit comments

Comments
 (0)