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: add read-only email subscription settings #987

Open
wants to merge 6 commits into
base: master
Choose a base branch
from

Conversation

wa0x6e
Copy link
Contributor

@wa0x6e wa0x6e commented Nov 24, 2024

Summary

Toward https://github.com/snapshot-labs/workflow/issues/226
Depends on snapshot-labs/snapshot-hub#951

This PR shows a read-only email subscriptions settings. (will pull status from the hub, and show relevant form/message depending on the subscription status)

Forms are not active yet, and submit as well as error validation does not work yet.

This is the first PR, among 2 PRs, to complete https://github.com/snapshot-labs/workflow/issues/226 (second one will focus on write features)

See figma: https://www.figma.com/design/hmHTau1Y1KYzrBBKLQr5QV/%23design?node-id=8192-7466&node-type=text&m=dev (the iteration without modal was implemented)

How to test

  1. Merge feat: return email subscription data in User snapshot-hub#951
  2. Go to http://localhost:8080/#/settings/email-notifications
  3. When logged in, it should show the email subscription page. The page should show different things depending on your subscription status (NOT_SUBSCRIBED, UNVERIFIED, VERIFIED). The menu item in the left navigation sidebar is hidden, until write functions are implemented.
  4. When logged out, it should open the account modal.

NOT_SUBSCRIBED

When you're not subscribed or logged out, will show a form to subscribe

UNVERIFIED

When you're subscribed, but have not verified the email yet. Will show a message with the steps required to verify the email, with a button to resend the verification email. There's no button to edit email (not an existing feature).

Test by connecting as 0xab54624A67E8c018a06B176bAAE76a40a385A464

VERIFIED

When the email is verified, will show the list of possible subscription types, with a toggle to switch them on/off.

Test by connecting as 0x91FD2c8d24767db4Ece7069AA27832ffaf8590f3

To-Do

Next PR will implement write features

@wa0x6e wa0x6e force-pushed the feat-email-subscription branch 2 times, most recently from 97dabe1 to 9cb595b Compare November 24, 2024 05:40
@bonustrack
Copy link
Member

bonustrack commented Dec 2, 2024

Once hub is merged, can we add a item on the settings menu "Notifications", and hide this item menu for testnet env

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants