Skip to content

Commit 0607ea9

Browse files
committed
chore: add GitHub nav button and fix viewport overflow
Adds a GitHub link to the top nav and fixes page containers that used min-height: 100vh alongside the nav, causing an unwanted scrollbar. Switches #app to a flex column and makes page roots flex: 1.
1 parent f23c229 commit 0607ea9

4 files changed

Lines changed: 30 additions & 4 deletions

File tree

src/App.vue

Lines changed: 25 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<script setup lang="ts">
2-
import { mdiHome, mdiLogin, mdiViewDashboard } from '@mdi/js'
2+
import { mdiGithub, mdiHome, mdiLogin, mdiViewDashboard } from '@mdi/js'
33
44
defineOptions({ name: 'App' })
55
</script>
@@ -24,6 +24,17 @@
2424
</svg>
2525
Dashboard
2626
</router-link>
27+
<a
28+
class="dk-nav__link dk-nav__link--github"
29+
href="https://github.com/vuetifyjs/devkey"
30+
target="_blank"
31+
rel="noopener"
32+
>
33+
<svg class="dk-icon" viewBox="0 0 24 24" width="16" height="16">
34+
<path :d="mdiGithub" fill="currentColor" />
35+
</svg>
36+
GitHub
37+
</a>
2738
</nav>
2839

2940
<router-view />
@@ -36,12 +47,21 @@
3647
box-sizing: border-box;
3748
}
3849
50+
html, body, #app {
51+
height: 100%;
52+
}
53+
3954
body {
4055
font-family: 'Inter', sans-serif;
4156
background: var(--v0-theme-background);
4257
color: var(--v0-theme-text);
4358
}
4459
60+
#app {
61+
display: flex;
62+
flex-direction: column;
63+
}
64+
4565
.dk-nav {
4666
display: flex;
4767
gap: 1rem;
@@ -78,4 +98,8 @@
7898
.dk-nav__link.router-link-active {
7999
color: var(--v0-theme-primary);
80100
}
101+
102+
.dk-nav__link--github {
103+
margin-left: auto;
104+
}
81105
</style>

src/components/DkLayout.vue

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,8 @@
2323
<style scoped>
2424
.dk-layout {
2525
display: flex;
26-
min-height: 100vh;
26+
flex: 1;
27+
min-height: 0;
2728
background: var(--v0-theme-background);
2829
}
2930

src/pages/LandingPage.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -115,7 +115,7 @@
115115
.dk-landing {
116116
background: var(--v0-theme-background);
117117
color: var(--v0-theme-text);
118-
min-height: 100vh;
118+
flex: 1;
119119
}
120120
121121
.dk-landing__hero {

src/pages/LoginPage.vue

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,15 +71,16 @@
7171
<style scoped>
7272
.dk-login {
7373
display: flex;
74+
flex: 1;
7475
align-items: center;
7576
justify-content: center;
76-
min-height: 100vh;
7777
background: var(--v0-theme-background);
7878
}
7979
8080
.dk-login__card {
8181
max-width: 420px;
8282
width: 100%;
83+
height: auto;
8384
padding: 2rem;
8485
}
8586

0 commit comments

Comments
 (0)