snapshot-labs / sx-monorepo

Snapshot monorepo
https://snapshot.box
MIT License
16 stars 16 forks source link

fix: show vote reason #476

Closed wa0x6e closed 3 months ago

wa0x6e commented 3 months ago

Summary

This PR fetch the vote reason from the API, and show it on the proposals' vote page, following the figma here https://www.figma.com/design/hmHTau1Y1KYzrBBKLQr5QV/%23design?node-id=1243-10592&t=zNyM96TSGyLdmPjt-0

Changes

How to test

  1. Go to a basic choice proposal: http://localhost:8080/#/s:apecoin.eth/proposal/0xf0ccdfb38ea5bee47e5f3f5ac83d5d9ecbeb605e328001c0ab4c6df7e91557e3/votes
  2. It should show the basic choice with the new UI, as well as reason
  3. Clicking on a choice with reason will open the reason modal
  4. Go to a non-basic choice proposal: http://localhost:8080/#/s:apecoin.eth/proposal/0xd7a0d880fa558f3e7308113545a668d29dd4ed3fc10453ea7f1c2209d7b13f86/votes
  5. It should show the reason below the choice when available, with a modal open on click
  6. Go to an starknet proposal: http://localhost:8080/#/sn-sep:0x018df40f9cb5ac1b43a3c9291ebc02903f01e8241bd959520b36e7e293ace65f/proposal/3/votes
  7. It should show the reason

To-Do before/after merge

wa0x6e commented 3 months ago

Maybe we could merge this one first, before the one writing reason, so we could test the writing PR more easily ?

Sekhmet commented 3 months ago

https://github.com/snapshot-labs/sx-monorepo/pull/519 was merged, can you rebase so all networks work?

Sekhmet commented 3 months ago

@wa0x6e I see on Figma there is more complex UI for Reason modal, are you planning on updating it in further PR?

image
wa0x6e commented 3 months ago

@wa0x6e I see on Figma there is more complex UI for Reason modal, are you planning on updating it in further PR?

image

Yes, I will leave it to later PR. Each time I look at the figma, something's changing. Better to wait for the final UI for this modal content before making further update

Sekhmet commented 3 months ago

Got it, we will merge this PR but I removed Closes: tag so we know that this design is still missing.