|
| 1 | +<!-- |
| 2 | + Navbar |
| 3 | + -- |
| 4 | + This component is static on the top of the page and displays links to different parts |
| 5 | + the screen |
| 6 | +--> |
| 7 | + |
| 8 | +<template> |
| 9 | + <v-app-bar app color="rgba(0,0,51,0.7)" elevation="0" width="100vw"> |
| 10 | + <!-- Large screen display --> |
| 11 | + <v-container class="hidden-sm-and-down"> |
| 12 | + <v-row class="d-flex justify-center"> |
| 13 | + <v-col class="d-flex align-center justify-start"> |
| 14 | + <a @click="goto('showcase')" style="text-decoration: none;"> |
| 15 | + <v-img contain max-height="60px" max-width="100px" src="@/assets/csesocwhiteblue.png" /> |
| 16 | + </a> |
| 17 | + </v-col> |
| 18 | + <v-col class="d-flex align-center justify-center"> |
| 19 | + <a @click="goto('mission')" style="text-decoration: none;"> |
| 20 | + <v-btn text color="white">ABOUT US</v-btn> |
| 21 | + </a> |
| 22 | + </v-col> |
| 23 | + <v-col class="d-flex align-center justify-center"> |
| 24 | + <a @click="goto('student-resources')" style="text-decoration: none;"> |
| 25 | + <v-btn text color="white">GET IN TOUCH</v-btn> |
| 26 | + </a> |
| 27 | + </v-col> |
| 28 | + <v-col class="d-flex align-center justify-center"> |
| 29 | + <a @click="goto('student-resources')" style="text-decoration: none;"> |
| 30 | + <v-btn text color="white">RESOURCES</v-btn> |
| 31 | + </a> |
| 32 | + </v-col> |
| 33 | + <v-col class="d-flex align-center justify-center"> |
| 34 | + <v-btn text to="/sponsorship" color="white">SPONSORSHIP</v-btn> |
| 35 | + </v-col> |
| 36 | + </v-row> |
| 37 | + </v-container> |
| 38 | + |
| 39 | + <!-- Smaller screen container --> |
| 40 | + <v-container class="hidden-md-and-up"> |
| 41 | + <v-row class="d-flex justify-space-between"> |
| 42 | + <v-col class="d-flex align-center"> |
| 43 | + <RouterLink to="/" style="text-decoration: none;" v-on:click.native="showMenu = false"> |
| 44 | + <v-img contain max-height="40px" max-width="100px" src="@/assets/csesocwhiteblue.png" /> |
| 45 | + </RouterLink> |
| 46 | + </v-col> |
| 47 | + <v-col class="d-flex justify-end"> |
| 48 | + <v-menu bottom left> |
| 49 | + <template v-slot:activator="{ on, attrs }"> |
| 50 | + <v-btn dark icon v-bind="attrs" v-on="on"> |
| 51 | + <v-icon>mdi-menu</v-icon> |
| 52 | + </v-btn> |
| 53 | + </template> |
| 54 | + <v-list> |
| 55 | + <v-list-item> |
| 56 | + <a @click="goto('mission')" style="text-decoration: none; color: black;"> |
| 57 | + About us |
| 58 | + </a> |
| 59 | + </v-list-item> |
| 60 | + <v-list-item> |
| 61 | + <a @click="goto('community')" style="text-decoration: none; color: black;"> |
| 62 | + Get in touch |
| 63 | + </a> |
| 64 | + </v-list-item> |
| 65 | + <v-list-item> |
| 66 | + <a @click="goto('student-resources')" style="text-decoration: none; color: black;"> |
| 67 | + Resources |
| 68 | + </a> |
| 69 | + </v-list-item> |
| 70 | + <v-list-item> |
| 71 | + <RouterLink style="text-decoration: none; color: black;" to="/sponsorship"> |
| 72 | + Sponsorship |
| 73 | + </RouterLink> |
| 74 | + </v-list-item> |
| 75 | + </v-list> |
| 76 | + </v-menu> |
| 77 | + </v-col> |
| 78 | + </v-row> |
| 79 | + </v-container> |
| 80 | + </v-app-bar> |
| 81 | +</template> |
| 82 | + |
| 83 | +<script type="text/javascript"> |
| 84 | +export default { |
| 85 | + name: 'Navbar', |
| 86 | + methods: { |
| 87 | + goto(refName) { |
| 88 | + const element = document.getElementById(refName); |
| 89 | + element.scrollIntoView({ block: 'start', behavior: 'smooth' }); |
| 90 | + } |
| 91 | + } |
| 92 | +}; |
| 93 | +</script> |
0 commit comments