From 0f02142eb1b4cbaa878b9ea961745ae8100b595a Mon Sep 17 00:00:00 2001 From: SauceyRed Date: Sat, 16 Aug 2025 14:25:11 +0200 Subject: [PATCH] feat: replace context menu items splicing with implementation of context menu item sections --- app.vue | 4 +- components/Guild/MemberEntry.vue | 4 +- components/Message.vue | 41 +++++++++++-------- components/UserInterface/ContextMenu.vue | 26 ++++++++---- components/UserInterface/ResizableSidebar.vue | 23 +++++++---- types/interfaces.ts | 7 +++- utils/createMemberContextMenuItems.ts | 18 +++++--- utils/removeContextMenu.ts | 2 +- utils/showContextMenu.ts | 10 ++--- 9 files changed, 85 insertions(+), 50 deletions(-) diff --git a/app.vue b/app.vue index 72bffa2..9fb1768 100644 --- a/app.vue +++ b/app.vue @@ -1,7 +1,7 @@ @@ -12,7 +12,7 @@ import type { ContextMenuInterface } from './types/interfaces'; const banner = useState("banner", () => false); -const contextMenu = useState("contextMenu", () => ({ show: false, pointerX: 0, pointerY: 0, items: [] })); +const contextMenu = useState("contextMenu", () => ({ show: false, pointerX: 0, pointerY: 0, sections: [] })); onMounted(() => { loadPreferredThemes() diff --git a/components/Guild/MemberEntry.vue b/components/Guild/MemberEntry.vue index f0a8aa5..e7fcbab 100644 --- a/components/Guild/MemberEntry.vue +++ b/components/Guild/MemberEntry.vue @@ -1,5 +1,5 @@