More improvements to context menu #69

Merged
sauceyred merged 31 commits from context-menu-ban-kick into main 2025-08-16 14:08:33 +00:00
Owner

Closes #66

Closes #66
feat: add hasPermission util to check if a member has a specific permission
All checks were successful
ci/woodpecker/push/build-and-publish Pipeline was successful
aecbcaefba
Merge branch 'main' into permissions-management
All checks were successful
ci/woodpecker/push/build-and-publish Pipeline was successful
ci/woodpecker/pr/build-and-publish Pipeline was successful
9fe067ec5a
feat: move context menu to the left of the cursor if any part of it is beyond the right side of the viewport
All checks were successful
ci/woodpecker/push/build-and-publish Pipeline was successful
ci/woodpecker/pr/build-and-publish Pipeline was successful
0540f22f5d
Twig approved these changes 2025-08-07 20:57:28 +00:00
Dismissed
Twig left a comment
Owner

looks good, but be careful when merging with the message component changes i made in #65

looks good, but be careful when merging with the message component changes i made in #65
feat: add ability to open member context menu by right-clicking on avatar
All checks were successful
ci/woodpecker/push/build-and-publish Pipeline was successful
ci/woodpecker/pr/build-and-publish Pipeline was successful
b0d96faa6f
Twig changed title from Add ban and kick to context menu to wip: Add ban and kick to context menu 2025-08-11 00:49:57 +00:00
fix: missing @contextmenu listeners in Message.vue after merging main
All checks were successful
ci/woodpecker/push/build-and-publish Pipeline was successful
ci/woodpecker/pr/build-and-publish Pipeline was successful
2e8f67133c
fix: CSS merged from main in wrong location
All checks were successful
ci/woodpecker/push/build-and-publish Pipeline was successful
ci/woodpecker/pr/build-and-publish Pipeline was successful
574ebe8850
feat: implement Confirmation modal on kick and ban context menu actions
All checks were successful
ci/woodpecker/push/build-and-publish Pipeline was successful
ci/woodpecker/pr/build-and-publish Pipeline was successful
3a9df965c2
sauceyred changed title from wip: Add ban and kick to context menu to Add ban and kick to context menu 2025-08-16 10:02:24 +00:00
sauceyred 2025-08-16 10:02:28 +00:00
  • removed the
    WIP
    label
  • requested review from Twig
sauceyred removed this from the Frontend MVP project 2025-08-16 10:34:44 +00:00
Twig requested changes 2025-08-16 11:00:30 +00:00
Dismissed
@ -0,0 +15,4 @@
<script lang="ts" setup>
import Button from '../UserInterface/Button.vue';
const props = defineProps<{ actionName: string, displayName?: string, callback: CallableFunction, onClose: () => void, onCancel: () => void }>();
Owner

i don't think "displayName" is the correct term here, assuming this is a generic confirmation screen, either rename the prop to "target" or something, or rename the modal

i don't think "displayName" is the correct term here, assuming this is a generic confirmation screen, either rename the prop to "target" or something, or rename the modal
Author
Owner

Are you saying displayName isn't intuitive, or is it something else?

Are you saying `displayName` isn't intuitive, or is it something else?
Owner

well displayName seems wrong if you're talking about a server, or a role. I think of it has a member thing

well displayName seems wrong if you're talking about a server, or a role. I think of it has a member thing
Author
Owner

Good point, I didn't think about that lmao

Good point, I didn't think about that lmao
sauceyred marked this conversation as resolved
@ -0,0 +19,4 @@
console.log("[MENUITEM] member is not me");
if (hasPermission(me.value, Permission.KickMember)) {
console.log("[MENUITEM] has kick member permission");
menuItems.splice(Math.min(3, menuItems.length), 0, {
Owner

splicing like this seems really messy, there should really be a better way of doing this

splicing like this seems really messy, there should really be a better way of doing this
Author
Owner

The purpose was mainly to make sure they would be put in the same order, but yeah I should take another look at it. I already have an idea.

The purpose was mainly to make sure they would be put in the same order, but yeah I should take another look at it. I already have an idea.
sauceyred marked this conversation as resolved
requested review from Twig 2025-08-16 12:26:54 +00:00
Twig approved these changes 2025-08-16 12:26:55 +00:00
Dismissed
Author
Owner

Example of when a menu has two sections:
image

Example of when a menu has two sections: ![image](/attachments/641d723d-dd2d-423e-b55d-80df81a6d4ed)
Author
Owner

Did you even look through the changes??

Did you even look through the changes??
Owner

@sauceyred wrote in #69 (comment):

Did you even look through the changes??

yeah, only took 2 minutes

@sauceyred wrote in https://git.gorb.app/gorb/frontend/pulls/69#issuecomment-1362: > Did you even look through the changes?? yeah, only took 2 minutes
Author
Owner

Alrighty then

Alrighty then
fix: kick and ban context menu items showing in wrong order due to use of splicing instead of pushing in createMemberContextMenuItems
All checks were successful
ci/woodpecker/push/build-and-publish Pipeline was successful
ci/woodpecker/pr/build-and-publish Pipeline was successful
ci/woodpecker/pull_request_closed/build-and-publish Pipeline was successful
dee08dd152
requested review from Twig 2025-08-16 13:54:54 +00:00
sauceyred changed title from Add ban and kick to context menu to More improvements to context menu 2025-08-16 13:55:16 +00:00
Twig approved these changes 2025-08-16 14:07:29 +00:00
sauceyred deleted branch context-menu-ban-kick 2025-08-16 14:08:33 +00:00
Sign in to join this conversation.
No reviewers
No milestone
No project
No assignees
2 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: gorb/frontend#69
No description provided.