-
Notifications
You must be signed in to change notification settings - Fork 115
Expand file tree
/
Copy pathAuthButtons.vue
More file actions
53 lines (47 loc) · 1.12 KB
/
AuthButtons.vue
File metadata and controls
53 lines (47 loc) · 1.12 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
<script setup lang="ts">
defineProps<{ place: 'navScreen' | 'navBar' }>();
</script>
<template>
<div :class="place === 'navScreen' ? 'navScreenContainer' : 'navBarContainer'">
<a href="https://stackblitz.com/sign_in" class="link light">Sign in</a>
<a href="https://stackblitz.com/register" class="link accent">Get started</a>
</div>
</template>
<style scoped lang="scss">
@import './linkStyles.scss';
/**
* When we have enough space, we show auth buttons in nav bar.
* When we don't, we show them inside the hamburger menu.
*/
.navBarContainer {
margin-inline-start: 40px;
display: flex;
gap: 8px;
// this is when we hide top nav menu
@media screen and (max-width: 768px) {
margin-inline-start: 0px;
}
@media screen and (max-width: 430px) {
display: none;
}
.link {
@media screen and (max-width: 700px) {
height: 30px;
padding: 0 10px;
}
}
}
.navScreenContainer {
display: none;
@media screen and (max-width: 400px) {
display: flex;
gap: 8px;
margin-block-start: 24px;
}
.link {
flex: 1;
justify-content: center;
height: 40px;
}
}
</style>