Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
web/satellite/v2: fix unauthenticated navigation
This change fixes an issue where navigating directly to a page when unauthenticated will show the page for a while before navigating to the login page, by introducing a full screen loader as seen in the V1 app. It also moves certain page setup calls (user, projects etc.) to App.vue so as not to replicate the login-redirect logic in more places. This also helps avoid calling for setup data that have already been fetched. Finally, navigation directly to the authentication pages is prevented. Issue: #6699 Change-Id: I3b5f8570c7d430f2afc5b0366f0e32852e4d1ae0
- Loading branch information
1 parent
8dd73e1
commit dd52ef2
Showing
13 changed files
with
208 additions
and
106 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
49 changes: 49 additions & 0 deletions
49
web/satellite/vuetify-poc/src/components/utils/BrandedLoader.vue
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
// Copyright (C) 2024 Storj Labs, Inc. | ||
// See LICENSE for copying information. | ||
|
||
<template> | ||
<div class="loader d-flex align-center justify-center"> | ||
<div class="loader__spinner" /> | ||
<img alt="loader" src="@/../static/images/common/loadIcon.svg" class="loader__icon"> | ||
</div> | ||
</template> | ||
|
||
<style scoped lang="scss"> | ||
@keyframes rotate { | ||
from { | ||
transform: rotate(0deg); | ||
} | ||
to { | ||
transform: rotate(360deg); | ||
} | ||
} | ||
.loader { | ||
position: absolute; | ||
inset: 0; | ||
&__spinner { | ||
width: 90px; | ||
height: 90px; | ||
margin: auto 0; | ||
border: solid 3px var(--c-blue-3); | ||
border-radius: 50%; | ||
border-right-color: transparent; | ||
border-bottom-color: transparent; | ||
border-left-color: transparent; | ||
transition: all 0.5s ease-in; | ||
animation-name: rotate; | ||
animation-duration: 1.2s; | ||
animation-iteration-count: infinite; | ||
animation-timing-function: linear; | ||
} | ||
&__icon { | ||
position: absolute; | ||
inset: 0; | ||
margin: auto; | ||
} | ||
} | ||
</style> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.