Skip to content

Commit

Permalink
Fix OAuth link
Browse files Browse the repository at this point in the history
  • Loading branch information
RomanSerikov committed Jan 28, 2021
1 parent f49c2f5 commit 4796666
Showing 1 changed file with 18 additions and 7 deletions.
25 changes: 18 additions & 7 deletions src/views/home/HomeToolbar.vue
Original file line number Diff line number Diff line change
@@ -1,6 +1,11 @@
<template>
<v-app-bar app clipped-left flat class="canvas pr-4">
<v-menu open-on-hover bottom offset-y v-if="!isAuthorized && config.oauth_enabled">
<v-menu
open-on-hover
bottom
offset-y
v-if="!isAuthorized && config.oauth_enabled"
>
<template v-slot:activator="{ on }">
<v-btn color="primary" text small v-on="on">
<v-icon class="mr-1" small>mdi-login</v-icon>Sign in
Expand All @@ -10,15 +15,15 @@
<v-list class="pa-0">
<v-list-item
class="d-flex align-center px-4"
:href="`${config.API_URI}oauth/github/login`"
:href="`${config.API_URI}/oauth/github/login`"
>
<v-list-item-title>
<v-icon class="mr-4">mdi-github</v-icon>GitHub
</v-list-item-title>
</v-list-item>
<v-list-item
class="d-flex align-center px-4"
:href="`${config.API_URI}oauth/gitlab/login`"
:href="`${config.API_URI}/oauth/gitlab/login`"
>
<v-list-item-title>
<v-icon class="mr-4">mdi-gitlab</v-icon>GitLab
Expand All @@ -29,7 +34,13 @@

<v-tooltip bottom v-else-if="profile != null">
<template v-slot:activator="{ on }">
<v-btn v-on="on" :to="{name: 'dashboard'}" fab small class="ml-2 mr-4">
<v-btn
v-on="on"
:to="{ name: 'dashboard' }"
fab
small
class="ml-2 mr-4"
>
<v-avatar size="40">
<img :src="profile.avatar_url" :alt="profile.login" />
</v-avatar>
Expand Down Expand Up @@ -96,14 +107,14 @@ export default {
},
apiDocsUrl() {
return `${window.location.origin}/docs`;
}
},
},
methods: {
toggleTheme() {
this.$vuetify.theme.dark = !this.$vuetify.theme.dark;
localStorage.setItem("dark", this.$vuetify.theme.dark);
}
}
},
},
};
</script>

Expand Down

0 comments on commit 4796666

Please sign in to comment.