feat: replace context menu items splicing with implementation of context menu item sections
All checks were successful
ci/woodpecker/push/build-and-publish Pipeline was successful
ci/woodpecker/pr/build-and-publish Pipeline was successful

This commit is contained in:
SauceyRed 2025-08-16 14:25:11 +02:00
parent c9bbd10af1
commit 0f02142eb1
Signed by: sauceyred
GPG key ID: 2BF92EB6D8A5CCA7
9 changed files with 85 additions and 50 deletions

View file

@ -1,7 +1,7 @@
<template>
<div>
<Banner v-if="banner" />
<ContextMenu v-if="contextMenu && contextMenu.show" :pointer-x="contextMenu.pointerX" :pointer-y="contextMenu.pointerY" :menu-items="contextMenu.items" />
<ContextMenu v-if="contextMenu && contextMenu.show" :pointer-x="contextMenu.pointerX" :pointer-y="contextMenu.pointerY" :menu-sections="contextMenu.sections" />
<NuxtPage :keepalive="true" />
</div>
</template>
@ -12,7 +12,7 @@ import type { ContextMenuInterface } from './types/interfaces';
const banner = useState("banner", () => false);
const contextMenu = useState<ContextMenuInterface>("contextMenu", () => ({ show: false, pointerX: 0, pointerY: 0, items: [] }));
const contextMenu = useState<ContextMenuInterface>("contextMenu", () => ({ show: false, pointerX: 0, pointerY: 0, sections: [] }));
onMounted(() => {
loadPreferredThemes()