habitica
habitica copied to clipboard
notifications for "Your Invitation has been Accepted" are not shown
When you invite someone to a group, if they accept the invitation, a notification is added to your notifications
array like this (this is working correctly as far as I am aware):
"notifications": [
{
"id": "6bab425b-4df3-49e5-8ac3-1872bc9de1e2",
"data": {
"headerText": "Your Invitation has been Accepted",
"bodyText": "Black Goblin accepted your invitation to Chaos Guild!"
},
"seen": false,
"type": "GROUP_INVITE_ACCEPTED"
},
}
However those notifications are never shown on the website.
To make them appear in the notifications panel, you'd need to add GROUP_INVITE_ACCEPTED
to this array in an appropriate place:
https://github.com/HabitRPG/habitica/blob/c875861dab131278d2e8897495ede426e430d533/website/client/components/header/notificationsDropdown.vue#L123-L133
My feeling is it could go between NEW_CHAT_MESSAGE
and UNALLOCATED_STATS_POINTS
because it feels to me that it's of roughly equal importance to those two, but if any of the staff post here with a different position in the array, listen to them not me. :)
There might be other changes needed too (e.g., tests).
Something that the staff might want to consider before any fix for this goes live:
All the GROUP_INVITE_ACCEPTED notifications have been building up in players' accounts for some time (maybe since the new website went live), so some people will have a lot of them and most of them will no longer be of interest to the players. Perhaps a migration could be done to delete all GROUP_INVITE_ACCEPTED notifications before they become visible on the website.
It might be most useful to do the deletion a few days before the fix goes live (e.g., at the time that the fix is merged to develop) because then when the fix does go live, recent notifications will become visible (the recent ones are likely to be of interest).
Anyone wanting to work on this should see the comments from @Tressley .
~I'm marking this as suggestion-discussion in case the staff want to add any comments. If there's no objections after a few days, I'll mark it as help wanted.~
I think we may need some design input from @Tressley on this one
Alright, I'm here to chime in!
@Alys -- I agree with your suggestion and think between NEW_CHAT_MESSAGE
and UNALLOCATED_STATS_POINTS
is perfect.
@thefifthisa -- Are you already a member of our Zeplin project? If not, can you please provide me with an email address (that you're okay being public), so I can send over an invite to our project? Zeplin is where we house our designs for hand-off to contributors.
This should be pretty straightforward as it should just re-use the same styling as GROUP_TASK_CLAIMED
notifications.
Is this still in progress?
I've marked this as help wanted again and tidied up the comments by removing some that were just about a claiming the issue. I've also edited the top post to direct attention to Tressley's comments.
@akmaekki If you're interested in working on this, post again here briefly, otherwise it can stay as help wanted until someone claims it.
Hi @Alys , I would like to work on this issue if it hasnt been claimed by someone!
Hi @cosmoglint, it's all yours! Thanks so much!