Final changes from self-review

This commit is contained in:
Georges-Antoine Assi
2023-08-18 23:18:38 -04:00
parent 4c02607027
commit 1fa06bb242
6 changed files with 9 additions and 10 deletions

View File

@@ -298,6 +298,5 @@ Games can be tagged with region, revision or other tags using parenthesis in the
# 🎖 Credits
* Pc icon support - <a href="https://www.flaticon.com/free-icons/keyboard-and-mouse" title="Keyboard and mouse icons">Keyboard and mouse icons created by Flat Icons - Flaticon</a>
* Login page background wallpaper - <a href="https://www.freepik.com/free-vector/colorful-futuristic-background-with-shiny-particles_9260185.htm#query=gaming%20background&position=29&from_view=keyword&track=ais">Image by pikisuperstar</a> on Freepik
* PC icon support - <a href="https://www.flaticon.com/free-icons/keyboard-and-mouse" title="Keyboard and mouse icons">Keyboard and mouse icons created by Flat Icons - Flaticon</a>
* Default user icon - <a target="_blank" href="https://icons8.com/icon/tZuAOUGm9AuS/user-default">User Default</a> icon by <a target="_blank" href="https://icons8.com">Icons8</a>

Binary file not shown.

Before

Width:  |  Height:  |  Size: 610 KiB

View File

@@ -105,7 +105,7 @@ onBeforeUnmount(() => {
>IGDB</v-chip
>
</v-item>
<!-- TODO: Ready item group to scrap from different sources -->
<!-- TODO: Ready item group to scrape from different sources -->
<!-- <v-item v-slot="{ isSelected, toggle }" disabled>
<v-chip class="mx-1" :color="isSelected ? 'rommAccent1' : 'rommGray'" variant="outlined" label @click="toggle"
>ScreenScraper</v-chip

View File

@@ -23,6 +23,8 @@ async function logout() {
})
.catch(() => {
router.push("/login");
}).finally(() => {
auth.setUser(null);
});
}
</script>

View File

@@ -27,7 +27,7 @@ const gettingRoms = ref(false);
const scanning = storeScanning();
const cursor = ref("");
const searchCursor = ref("");
const scrollOnTop = ref(true);
const scrolledToTop = ref(true);
// Event listeners bus
const emitter = inject("emitter");
@@ -125,9 +125,8 @@ function onFilterChange() {
}
function onScroll() {
const { scrollTop, scrollHeight, clientHeight } = document.documentElement;
scrollOnTop.value = scrollTop == 0 // Check scroll position to show fab to top
scrolledToTop.value = scrollTop == 0 // Check scroll position to show fab to top
if (cursor.value === null && searchCursor.value === null) return;
@@ -214,7 +213,7 @@ onBeforeRouteUpdate(async (to, _) => {
<v-layout-item
v-scroll="onScroll"
class="text-end"
:model-value="!scrollOnTop"
:model-value="!scrolledToTop"
position="bottom"
size="88"
>

View File

@@ -14,7 +14,6 @@ const password = ref();
const visiblePassword = ref(false);
function login() {
const token = btoa(`${username.value}:${password.value}`);
axios
.post(
"/api/login",
@@ -42,9 +41,9 @@ function login() {
}
onBeforeMount(async () => {
// Check if romm auth is enabled
// Check if authentication is enabled
if (!auth.enabled) {
router.push("/");
return router.push("/");
}
});
</script>