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: voting on proposals #69

Merged
merged 34 commits into from
Mar 13, 2024
Merged

Feat: voting on proposals #69

merged 34 commits into from
Mar 13, 2024

Conversation

denviljclarke
Copy link
Contributor

@denviljclarke denviljclarke commented Mar 5, 2024

Description

This PR completes the voting component on the proposal page. It adds the functionality to:

  • allow voting on active proposals if the user is eligible
  • display the appropriate view if the user is not eligible
  • display the appropriate view based on the proposal state if the proposal is inactive

I added a bit more information to the transaction in progress screen and an icon to the transaction submit success & transaction confirm states.

For reviewers: Ping me or @chapati23 for the pk to the dev wallet as it already has locked MENTO on alfajores which is needed to vote.

Other changes

  • added the brand font to the app
  • update the styling on the execution code card
  • moved the voting component to the correct position when in mobile based on designs
  • updated the apollo client config to use the new subgraph url

Tested

Ran the locally and ensured voting was working and the voting component displayed the correct view based on the different states of the proposal and the users 'hasVoted' status

Related issues

Copy link

vercel bot commented Mar 5, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
governance-ui ✅ Ready (Inspect) Visit Preview 💬 Add feedback Mar 13, 2024 5:27pm

@denviljclarke denviljclarke requested review from a team, bowd and RyRy79261 and removed request for a team March 6, 2024 00:30
@denviljclarke denviljclarke marked this pull request as ready for review March 6, 2024 00:48
Copy link
Contributor

@chapati23 chapati23 left a comment

Choose a reason for hiding this comment

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

nice work, voted for and against a proposal from different accounts and it all worked fine.

comments mainly on UX improvements and code structure

app/(routes)/proposals/[id]/_components/vote.component.tsx Outdated Show resolved Hide resolved
app/(routes)/proposals/[id]/_components/vote.component.tsx Outdated Show resolved Hide resolved
app/(routes)/proposals/[id]/_components/vote.component.tsx Outdated Show resolved Hide resolved
app/(routes)/proposals/[id]/_components/vote.component.tsx Outdated Show resolved Hide resolved
app/(routes)/proposals/[id]/_components/vote.component.tsx Outdated Show resolved Hide resolved
app/(routes)/proposals/[id]/_components/vote.component.tsx Outdated Show resolved Hide resolved
app/(routes)/proposals/[id]/_components/vote.component.tsx Outdated Show resolved Hide resolved
app/(routes)/proposals/[id]/page.tsx Outdated Show resolved Hide resolved
app/(routes)/proposals/[id]/_components/vote.component.tsx Outdated Show resolved Hide resolved
app/(routes)/proposals/[id]/_components/vote.component.tsx Outdated Show resolved Hide resolved
Copy link
Contributor

@RyRy79261 RyRy79261 left a comment

Choose a reason for hiding this comment

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

Looks good, I think we need to add frame to the wallet options as we're getting an RPC error

.env Outdated Show resolved Hide resolved
Copy link
Contributor

@chapati23 chapati23 left a comment

Choose a reason for hiding this comment

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

looks good, thanks for addressing all the comments, I know it was a lot!

just one last issue I found, probably merge conflict, there's a missing border on the cast-vote component when the proposal is already over:

image

Copy link
Contributor

@chapati23 chapati23 left a comment

Choose a reason for hiding this comment

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

lfg

@denviljclarke
Copy link
Contributor Author

looks good, thanks for addressing all the comments, I know it was a lot!

just one last issue I found, probably merge conflict, there's a missing border on the cast-vote component when the proposal is already over:

image

🫡
& Thanks, just fixed this. It was lost in the refactor.

@denviljclarke denviljclarke merged commit 7792f82 into develop Mar 13, 2024
3 checks passed
@denviljclarke denviljclarke deleted the feat/23-vote-on-proposal branch March 13, 2024 17:31
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.

4 participants