Skip to content

Commit 5b9cefc

Browse files
authored
Fix navbar links (#219)
1 parent dea1b3c commit 5b9cefc

File tree

9 files changed

+86
-10
lines changed

9 files changed

+86
-10
lines changed

frontend/src/App.vue

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
<template>
22
<v-app id="main-app">
3-
<Navbar />
43
<v-main class="pa-0">
54
<Menu v-if="showMenu" @shown="onMenuCollapse" />
65
<RouterView style="overflow-x: hidden" />
@@ -12,7 +11,7 @@
1211
<script>
1312
import Footer from '@/components/Footer';
1413
import Menu from '@/components/Menu';
15-
import Navbar from '@/components/Navbar';
14+
// import Navbar from '@/components/Navbar';
1615
1716
export default {
1817
name: 'App',
@@ -22,7 +21,7 @@ export default {
2221
components: {
2322
Footer,
2423
Menu,
25-
Navbar,
24+
// Navbar,
2625
},
2726
methods: {
2827
onMenuCollapse(val) {

frontend/src/components/Navbar.vue renamed to frontend/src/components/PrimaryNavbar.vue

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
<!--
2-
Navbar
2+
PrimaryNavbar
33
--
4-
This component is static on the top of the page and displays links to different parts
5-
the screen
4+
This component is static on the top of Home page and links to different parts of the screen.
5+
Also links to the Sponsorship page.
66
-->
77

88
<template>
@@ -92,7 +92,7 @@
9292

9393
<script type="text/javascript">
9494
export default {
95-
name: 'Navbar',
95+
name: 'PrimaryNavbar',
9696
methods: {
9797
goto(refName) {
9898
const element = document.getElementById(refName);
Lines changed: 63 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,63 @@
1+
<!--
2+
SecondaryNavbar
3+
--
4+
This component is static on the top of the About and Sponsorship pages. It links to
5+
each one and the home `/` page.
6+
-->
7+
8+
<template>
9+
<v-app-bar app color="rgba(0,0,51,0.9)" elevation="0" width="100vw">
10+
<!-- Large screen display -->
11+
<v-container class="hidden-sm-and-down">
12+
<v-row class="d-flex">
13+
<v-col class="d-flex ps-10 align-center justify-start">
14+
<RouterLink to="/" style="text-decoration: none;" v-on:click.native="showMenu = false">
15+
<v-img contain max-height="60px" max-width="100px" src="@/assets/csesocwhiteblue.png" />
16+
</RouterLink>
17+
</v-col>
18+
<v-col class="d-flex align-center justify-end pr-10">
19+
<v-btn text to='/about' class="mr-2" color="white">ABOUT US</v-btn>
20+
<v-btn text to="/sponsors" class="ms-2" color="white">SPONSORSHIP</v-btn>
21+
</v-col>
22+
</v-row>
23+
</v-container>
24+
25+
<!-- Smaller screen container -->
26+
<v-container class="hidden-md-and-up">
27+
<v-row class="d-flex justify-space-between">
28+
<v-col class="d-flex align-center">
29+
<RouterLink to="/" style="text-decoration: none;" v-on:click.native="showMenu = false">
30+
<v-img contain max-height="40px" max-width="100px" src="@/assets/csesocwhiteblue.png" />
31+
</RouterLink>
32+
</v-col>
33+
<v-col class="d-flex justify-end">
34+
<v-menu bottom left>
35+
<template v-slot:activator="{ on, attrs }">
36+
<v-btn dark icon v-bind="attrs" v-on="on">
37+
<v-icon>mdi-menu</v-icon>
38+
</v-btn>
39+
</template>
40+
<v-list>
41+
<v-list-item>
42+
<RouterLink to="/about" style="text-decoration: none; color: black;">
43+
About us
44+
</RouterLink>
45+
</v-list-item>
46+
<v-list-item>
47+
<RouterLink style="text-decoration: none; color: black;" to="/sponsors">
48+
Sponsorship
49+
</RouterLink>
50+
</v-list-item>
51+
</v-list>
52+
</v-menu>
53+
</v-col>
54+
</v-row>
55+
</v-container>
56+
</v-app-bar>
57+
</template>
58+
59+
<script type="text/javascript">
60+
export default {
61+
name: 'SecondaryNavbar',
62+
};
63+
</script>

frontend/src/views/About.vue

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@
1111

1212
<template>
1313
<v-app>
14+
<SecondaryNavbar />
1415
<v-parallax height="300" src="../assets/fade.png"></v-parallax>
1516
<!-- About -->
1617
<v-container ref="content-start" style="padding: 0px 30px 10px 30px">
@@ -317,6 +318,7 @@
317318

318319
<script>
319320
import HeaderTitle from '@/components/HeaderTitle';
321+
import SecondaryNavbar from '../components/SecondaryNavbar';
320322
321323
const fs = require('@/assets/execs_directs.json');
322324
@@ -326,7 +328,8 @@ export default {
326328
execsDirects: fs
327329
}),
328330
components: {
329-
HeaderTitle
331+
HeaderTitle,
332+
SecondaryNavbar
330333
}
331334
};
332335
</script>

frontend/src/views/Home/AboutUs.vue

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
</v-col>
1515
<v-col xs="12" sm="6" align-self="center">
1616
<p data-cy="mission-statement" class="text--md">{{ mission.statement }}</p>
17-
<v-btn to="/about" block outlined color="white" icon class="btn--sm">
17+
<v-btn block outlined color="white" icon class="btn--sm">
1818
SEE MORE
1919
</v-btn>
2020
</v-col>
@@ -45,4 +45,7 @@ export default {
4545
max-width: 100%;
4646
max-height: 100%;
4747
}
48+
.content {
49+
padding-top: 50px;
50+
}
4851
</style>

frontend/src/views/Home/CommunityLink.vue

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -138,6 +138,7 @@ export default {
138138
transform: scale(1.05);
139139
}
140140
.content {
141+
padding-top: 50px;
141142
@media screen and (max-width: 960px) {
142143
padding-left: 20px;
143144
padding-right: 20px;

frontend/src/views/Home/EventDisplay.vue

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,7 @@ export default {
7070
.Container {
7171
display: flex;
7272
flex-direction: row;
73+
padding-top: 50px;
7374
}
7475
.Embed {
7576
display: flex;

frontend/src/views/Home/Home.vue

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@
1313

1414
<template>
1515
<div id="home">
16+
<PrimaryNavbar />
1617
<!-- Showcase -->
1718
<Showcase />
1819
<!-- Mission -->
@@ -39,6 +40,7 @@ import Slideshow from '@/views/Home/Slideshow';
3940
import StudentResources from '@/views/Home/StudentResources';
4041
import SponsorUs from '@/views/Home/SponsorUs';
4142
import APIClient from '../../utils/APIClient';
43+
import PrimaryNavbar from '../../components/PrimaryNavbar';
4244
4345
export default {
4446
name: 'Home',
@@ -56,6 +58,7 @@ export default {
5658
Slideshow,
5759
StudentResources,
5860
SponsorUs,
61+
PrimaryNavbar,
5962
},
6063
mounted() {
6164
APIClient.eventsAPI()

frontend/src/views/Sponsor.vue

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88
-->
99
<template>
1010
<div>
11+
<SecondaryNavbar />
1112
<div class="down-button" @click="onClickScroll" @scroll.passive="handleScroll" ref="downButton">
1213
<img src="@/assets/downbutton.png" />
1314
</div>
@@ -89,6 +90,7 @@
8990

9091
<script type="text/javascript">
9192
import SponsorModal from '@/components/SponsorModal';
93+
import SecondaryNavbar from '@/components/SecondaryNavbar';
9294
9395
const sponsorData = require('@/assets/sponsors_mini.json');
9496
@@ -106,7 +108,8 @@ export default {
106108
smallLogoFilter: 5
107109
}),
108110
components: {
109-
SponsorModal
111+
SponsorModal,
112+
SecondaryNavbar
110113
},
111114
computed: {
112115
// functions to determine sizing category of sponsor based on their value

0 commit comments

Comments
 (0)