From 46f8930e6fba4b842012f61deb12f8713cb8b50a Mon Sep 17 00:00:00 2001 From: zurdi Date: Sat, 6 Jul 2024 03:33:18 +0200 Subject: [PATCH 001/273] protect urls behind permissions --- .../src/components/common/Game/Card/Base.vue | 33 ++++++++++++++++--- .../common/Game/Dialog/SearchRom.vue | 17 ++-------- frontend/src/components/common/RDialog.vue | 1 - frontend/src/plugins/router.ts | 19 +++++++++-- frontend/src/views/Gallery/Collection.vue | 8 ++--- frontend/src/views/Gallery/Platform.vue | 3 +- 6 files changed, 50 insertions(+), 31 deletions(-) diff --git a/frontend/src/components/common/Game/Card/Base.vue b/frontend/src/components/common/Game/Card/Base.vue index b58a4d49a..29500be60 100644 --- a/frontend/src/components/common/Game/Card/Base.vue +++ b/frontend/src/components/common/Game/Card/Base.vue @@ -3,12 +3,12 @@ import type { SearchRomSchema } from "@/__generated__"; import ActionBar from "@/components/common/Game/Card/ActionBar.vue"; import GameCardFlags from "@/components/common/Game/Card/Flags.vue"; import Sources from "@/components/common/Game/Card/Sources.vue"; +import PlatformIcon from "@/components/common/Platform/Icon.vue"; import storeCollections from "@/stores/collections"; import storeDownload from "@/stores/download"; import storeGalleryView from "@/stores/galleryView"; import storeRoms from "@/stores/roms"; import { type SimpleRom } from "@/stores/roms.js"; -import { storeToRefs } from "pinia"; import { onMounted, ref } from "vue"; import { useTheme } from "vuetify"; @@ -22,6 +22,7 @@ const props = withDefaults( pointerOnHover?: boolean; titleOnFooter?: boolean; showActionBar?: boolean; + showPlatformIcon?: boolean; showFav?: boolean; withBorder?: boolean; withBorderRommAccent?: boolean; @@ -34,6 +35,7 @@ const props = withDefaults( pointerOnHover: true, titleOnFooter: false, showActionBar: false, + showPlatformIcon: false, showFav: false, withBorder: false, withBorderRommAccent: false, @@ -153,7 +155,22 @@ onMounted(() => { -
+
+ + + +
+
- + + diff --git a/frontend/src/components/common/Collection/Card.vue b/frontend/src/components/common/Collection/Card.vue index e93992346..552e4f2d0 100644 --- a/frontend/src/components/common/Collection/Card.vue +++ b/frontend/src/components/common/Collection/Card.vue @@ -1,7 +1,9 @@