Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(web): email notification preference settings #9934

Merged
merged 7 commits into from
Jun 3, 2024

Conversation

alextran1502
Copy link
Contributor

This PR implements email notification settings for each user. The user can toggle to enable/disable the email notification entirely or selectively choose what type of email notificaton event (ALBUM INVITE, ALBUM UPDATE) to receive

Comment on lines +23 to +27
@ValidateBoolean({ optional: true })
albumInvite?: boolean;

@ValidateBoolean({ optional: true })
albumUpdate?: boolean;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm wondering if we want it to be more of an object structure. So something like { album: { invite: true, update: false }, ... }.

Copy link
Contributor Author

@alextran1502 alextran1502 Jun 2, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It would be more on the preference's response, which is already structured somewhat similar

    emailNotifications: {
      enabled: true,
      albumInvite: true,
      albumUpdate: true,
    },

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I saw that and I don't think it's structured similarly to my suggestion.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I want to keep it similar to the event for ease of tracking. Additionally, you need the master enabled flag for ease of mass toggle

@aviv926
Copy link
Contributor

aviv926 commented Jun 2, 2024

As part of adding the information to #9930, is this PR expected to cover the option to enable or disable email notifications for specific albums?

@alextran1502
Copy link
Contributor Author

@aviv926 No, it doesn't. This permission covers the blanket permissions for the album.

@alextran1502 alextran1502 merged commit b3ee394 into main Jun 3, 2024
22 checks passed
@alextran1502 alextran1502 deleted the feat/web-email-preference branch June 3, 2024 21:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants