Code Monkey home page Code Monkey logo

davi's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

davi's Issues

Balance field - interupted when trying to enter two digits

Description
When I try to enter amount in balance field and delete "0.0" As soon as I enter one digit the ".0" is being added, In order to add 2 digits number I have to navigate cursor to the left

Steps to Reproduce

  1. SpinUp Localhost env
  2. Open localhost:3000  
  3. Check if Landing Page is loaded  
  4. Click on REPuild box  
  5. Click on Join button
  6. Enter two digit amount of tokens in balance field

Expected behavior
Should be able to enter two digits number

Screenrecord
https://user-images.githubusercontent.com/37701286/176949510-7ff3cc9d-6c80-4687-91a3-eef2a219a497.mp4

Device Information
OS: MacOs
Browser GoogleChrome, Brave
Device: MacOS Monterey v12.4

Additional context
Added screenrecord for better understanding.

Update bytecode for goerli

Description
It seems our bytecode matching is not working for goerli and needs updated, might be fixed once updating after this is merged? DXgovernance/dxdao-contracts#147

Steps to Reproduce
Steps to reproduce the behavior:

  1. Go to goerli
  2. Click on swapr guild
  3. Create proposal
  4. Check if default "Against" option is added

Expected behavior
For swapr guild we should have default against in creation and snapshot voting messages when voting etc

Action Builder - Swapr pair input

We want an input type that shows a list of options and a search.
The first implementation will be to show a list of swapr pools for selection but the component should be generic for future use.
We can look at the current token picker for inspiration as it will likely be very similar

This should likely be a more generic list input that takes in a config.
The swapr pair list will be fetched from swapr subgraph then passing pairs and maybe their images and when clicked on returning the address of the pair.

{ pairs { poolAddress: id, token0 { address: id symbol name } token1 { address: id symbol name } } }

REPGuild page - Portfolio button redirection not working

Description:
When on any Guild page user should be able to access portfolio page of that Guild

Steps to Reproduce:

  1. SpinUp Localhost env
  2. Open localhost:3000
  3. Check if Landing Page is loaded
  4. Click on REPGuild box
  5. Click on Portfolio button

Actual behaviour:
Redirected to Landing page

Expected behavior:
User should be redirected to Guilds Portfolio page

Screenshots:
Screenshot 2022-06-29 at 22 20 32

Device Information

  • OS: MacOs
  • Browser GoogleChrome, Brave
  • Device: MacOS Monterey v12.4

Additional context
The same behaviour is for the all Guilds. This is an feature that is not developed or connected, it's not a bug

Modals take full height when in mobile view and overlay isn't applied to modals below

Description

  1. When in mobile view, modals take the full height of the page.
  2. When in mobile view, extra padding is applied.
  3. When opening two modals, the second one should be above the first one. However, the overlay isn't applied to the first modal, causing both to look like one, since they are the same color and the borders are not clearly defined.

Steps to Reproduce
For bugs 1 and 2: set the size of the window to 768px.

For bug 3:

  1. Go to the proposal creation page, add a new option and a new action.
  2. In the "new action" menu, select "Set Permissions".
  3. Click on the token picker to open a new modal.

Expected behavior

  • Modals maintain the size during screen size changes
  • Overlays are applied to modals behind them.

Screenshots
Modal on full-size screen:
Screenshot from 2022-06-07 08-24-48

Modal on a 768px screen:
Screenshot from 2022-06-07 08-25-10

Two modals overlapping:
Screenshot from 2022-06-07 08-29-49

Action Builder - JSON Diff

As a security measure for configurations we store on IPFS and access via ens we need some easy way of verifying json files as someone could very easily sneak in small changes to rich contract json for a malicious attack.
On the UI we will determine if the new and old ipfs files are json when updating ens and then display this component to show a diff of the changes, much like what github does.
It should be very clear and easy to view, maybe in the action dropdown.

Refactor web3 wallet and network integration

After splitting the DAVI and dxvote repos, there's a lot of legacy code left in the DAVI repo around the web3 integration. We should refactor and cleanup the existing code, with a focus on making it simpler and easier to maintain.

We should also look at upgrading to web3-react v8 or wagmi. Both of these libraries are hooks-first, and better suits our current architecture better,

Action Builder - Edit button

We have an edit button but currently it does not do anything. We should show the edit modal that was used to create that action from the very start (including any approvals)

Search field bar at Guild Page don't work

Description
When user click on Search field bar at Guild Page, then can see cursor next to magnifying glass icon. But when user enter some title, ENS or address, then nothing appears in field. User should be able to submit title, ENS or address and to see results from search.

Steps to Reproduce
Steps to reproduce the behavior:

  1. SpinUp Localhost env
  2. Open localhost:3000
  3. Check if Landing Page is loaded
  4. Click on SWPRGuild box
  5. Click on magnifying glass icon next to Create Proposal button
  6. Enter title, ENS or address of Proposal which you want to search

Expected behavior
Title, ENS or address which enter appear in search field bar. User can search it when press 'Enter', and should see search results.

Actual behavior
Title, ENS or address which enter don't appear in search field bar and User can't search it

Screenshots
Screenshot 2022-06-27 at 18 47 18

Device Information

  • OS: MacOs
  • Browser GoogleChrome, Brave
  • Device: MacOS Monterey v12.4

Additional context
Expect from Search bar to work and can do some input

Discussions view

On the main page of guilds right now we show just active proposals in a large card with proposal details. These will of course have their own discussions but I think its important also to separate discussions which are not yet on chain proposals.

Perhaps this should be a list underneath? This can include key metrics like most recent post time, number of comments, tags and in future even how many times the discussion has gone to a vote.

REPGuild page - Settings button redirection not working

Description:
When on any Guild page user should be able to access the settings page of that Guild

Steps to Reproduce:

  1. SpinUp Localhost env
  2. Open localhost:3000
  3. Check if Landing Page is loaded
  4. Click on REPGuild box
  5. Click on Settings button

Actual behaviour:
Redirected to Landing page

Expected behavior:
User should be redirected to Guilds Settings page

Screenshots:
Screenshot 2022-06-29 at 22 23 53

Device Information

  • OS: MacOs
  • Browser GoogleChrome, Brave
  • Device: MacOS Monterey v12.4

Additional context
The same behaviour is for the all Guilds. This is an feature that is not developed or connected, it's not a bug

Go through disabled exhaustive deps

We did not have time to go through all of the cases where we had exhaustive deps warnings with eslint but wanted a clean console so have disabled it.
We have to go through and make sure which cases should actually have this disabled and which we should be adding or fixing to prevent the warning.
#6
99eb7a5

Voting for option on some proposal does not work as expected

Description
When I select option to vote for, confirm transaction i do not see any changes on proposal page, under vote section

Steps to Reproduce

  1. SpinUp Localhost env  
  2. Open localhost:3000  
  3. Check if Landing Page is loaded  
  4. Click on DXDGuild box
  5. Click on Active Proposal
  6. Select the option to vote for and confirm transaction
  7. "Vote on proposal [proposal name]" transaction is visible under recent transaction

Expected behavior
Vote should impact the selected option on vote section, there should be visible change

Actual behavior
No visible changes on voting section, not even after page refresh

Screenshots
dxd1
dxd2

Device Information
OS: MacOs
Browser GoogleChrome, Brave
Device: MacOS Monterey v12.4

Additional context
Transaction is visible under Recent transactions (top-right corner, account address icon)

Lock token state not updating fast enough in stake modal

In stake modal we see the transaction complete well before the UI updates to allow locking of tokens causing confusion to the user. We should be able to fix this by updating SWR polling rate for this specifically I think.

Get orbit db working again

We have a branch that Carl was working on previously (https://github.com/DXgovernance/DAVI/tree/feature/forum) but it seems there is an inherit issue with orbit DB working, replicating data. It probably needs someone to take a proper deep dive.
Previously we had signed voting also using orbit db working in dxvote but that also seems broken, maybe @AugustoL you could have a look as the one with most IPFS knowledge?

I also tried connecting orbit db to my personal ipfs node locally and on my dappnode but didn't get very far, maybe we could use a list of our nodes in dxdao to support this.

Landing page filtering

We need some way of sorting for guilds and dxvote DAOs on the DAVI landing page. We only have guilds right now but in future they ill be mixed together.

We could also do with a label to highlight which type is shown if they are all mixed together with no filtering

Enforced Binary features in base guild support

Currently when creating a proposal in an enforced binary guild we have the against option but it shows "1 on-chain action" in the action overview. We should check for data 0x0 to address 0x0 with value 0 and mark that as 0 on chain actions

EDIT
Turning this into the issue for adapting to the new default base guild working as an enforced guild

Refactor the duration picker

The current duration picker component is an uncontrolled input component. While this is not bad, our current implementation for the action builder dynamic form renderer expects input components to be controlled components. Right now this means when editing an action in the action builder, the existing values are not shown for the duration picker.

We should refactor the duration picker to be controlled. (It should take the value and onChange props as input and shouldn't keep an internal state.)

REPGuild page - Proposals button redirection not working

Description
When on any Guild page user should be able to access the list of all proposals within that Guild

Steps to Reproduce

  1. SpinUp Localhost env
  2. Open localhost:3000  
  3. Check if Landing Page is loaded  
  4. Click on REPGuild box
  5. Click on Proposals button

Actual behavior
Redirected to Landing page

Expected behavior
User should be redirected to Guilds Proposal page

Screenshots
proposal

Device Information
OS: MacOs
Browser GoogleChrome, Brave

Device: MacOS Monterey v12.4

Additional context
The same behaviour is for the all Guilds. This is an feature that is not developed or connected, it's not a bug

Support filtering of proposals

We have the UI elements and component logic for filtering but we don't actually do any to the list of proposals.

For this we will need to populate the filter drop downs with actual options:
State: Use enum ProposalState (not contractState)
Type: Lets rename this "Actions" and for now add our list of core actions (transfer+permissions+ens) we will then check against the proposals list of actions.
Currency: Use token list and check against tokens being transferred in the actions list

IPFS non-base58 error

Description
It seems occasionally we get an error creating proposals when uploading metadata to ipfs. On localhost this appears as a full error "non-base58". Not sure how to reliably replicate

Steps to Reproduce
Steps to reproduce the behavior:

  1. Create proposal
  2. Add text
  3. Create proposal
  4. Check if errors - shouldn't go to transaction if error is found

Expected behavior
Creates transaction and description is viewable in proposal page after

Action Builder - Support factory created contracts in rich contract config

Currently, we match contracts via addresses and this is great when we have one type of contract to interact with.
But when we have contracts to interact with that are created by factories like with uniswap v2 (bad example as we will solve this with swapr SDK but good for visualisation) we don't have one specific address to match.
We then cant rely on function signatures due to it not being unique.
But instead, we can use bytecode to match this. We'll need to add an additional hashed bytecode value to rich contract data and for these configs we will just leave network addresses blank for each network to signify that it is a factory generated contract.

Link double slash

Description
It seems occasionally when clicking around the UI it is possible to go back then click on a link which appends a double // to the URL causing the app to break

View on Block Explorer hyperlink not working

Description
After user hase connected his wallet to MetaMask he should be able to inspect his account on Block Explorer

Steps to Reproduce
Steps to reproduce the behavior:

  1. SpinUp Localhost env
  2. Open localhost:3000
  3. Check if Landing Page is loaded
  4. Connect wallet
  5. Click on Account address icon
  6. Click on View on Block Explorer hyperlink

Expected behavior
User should be redirected to explorer

Actual behavior
Redirected to Landing page of Guilds

Screenshots
Screenshot 2022-06-27 at 18 55 24

Device Information

  • OS: MacOs
  • Browser GoogleChrome, Brave
  • Device: MacOS Monterey v12.4

Additional context
Just wondering, do we have some explorer where user need to be redirected or it's in WIP? If it's in WIP, this is not a bug just feature

Missing Members icon and Information button

Description
Members are displayed below Guild title, but should be displayed at top-left corner of Guild main box.
Information button is missing. Should be displayed at top right corner of Guild main box.

Steps to Reproduce

  1. SpinUp Localhost env
  2. Open localhost:3000
  3. Check if Landing Page is loaded
  4. Click on SWPRGuild box

Expected behavior
dao1

Actual behavior
dao2

Device Information
OS: MacOs
Browser GoogleChrome, Brave
Device: MacOS Monterey v12.4

Lock SWPR token button changing name

Description
When Stake form is open "Lock SWPR" button is visible (screenshot1), if I delete digits from Balance field button changes name to "Approve SWPR Spending" (screenshot2), then changes back again as soon as I enter any digit

Steps to Reproduce

  1. SpinUp Localhost env
  2. Open localhost:3000
  3. Check if Landing Page is loaded
  4. Click on REPuild box
  5. Click on Join button
  6. Delete amount in Balance field
  7. Check "Lock SWPR" button name
  8. Enter amount in Blance Field
  9. Check "Lock SWPR" button name

Expected behavior
Button name should be the same

Actual behavior
Button name changes when I delete amount from the field, and changes back again when I enter amount in Balance field

Screenshots
dxd1
dxd2

Device Information
OS: MacOs
Browser GoogleChrome, Brave
Device: MacOS Monterey v12.4

Additional context
The same behaviour is for the all Guilds.

Search Guild field bar don't work

Description
When user click on Search Guild field bar, then can see cursor next to magnifying glass icon. But when user enter some word, that word doesn't appear in field. User should be able to submit word and to see results from search.

Steps to Reproduce
Steps to reproduce the behavior:

  1. SpinUp Localhost env
  2. Open localhost:3000
  3. Check if Landing Page is loaded
  4. Click on Search Guild field bar
  5. Enter name of Guild which you want to search

Expected behavior
Word which enter appear in Search Guild field bar. User can search it when press 'Enter', and should see search results.

Actual behavior
Word which enter don't appear in Search Guild field bar and User can't search it

Screenshots
Screenshot 2022-06-27 at 18 40 54

Device Information

  • OS: MacOs
  • Browser GoogleChrome, Brave
  • Device: MacOS Monterey v12.4

Additional context
Expect from Search bar to work and can do some input

Cache Refactor - Reputation mobbing session

We need to make a start on cache refactors and I think the best way to do that will be to go over it again as a group to discuss how to go about it to further split up future sections.

We'll schedule this once UI refactors are complete.

SWPRGuild - wrong staking period time

Description:
When I join the guild it says staking period is 5min but after that it says it is unlocked in 1h

Steps to Reproduce:

  1. SpinUp Localhost env
  2. Open localhost:3000
  3. Check if Landing Page is loaded
  4. Click on SWPRGuild box
  5. Click on Join button
  6. Enter amount of tockens and confirm transaction
  7. Click on account address under Guilds name
  8. Check "unlocked in" info

Actual behaviour:
Staking period lasts 1h

Expected behavior:
Staking period should be 5 min

Screenshots:
Screenshot 2022-06-29 at 22 39 19
Screenshot 2022-06-29 at 22 39 57
286/176540581-738f5135-9707-4189-af2a-3e234bb83c53.png">

Device Information

  • OS: MacOs
  • Browser GoogleChrome, Brave
  • Device: MacOS Monterey v12.4

Additional context
Expecting to be 5min but it's 1h. Maybe is something with config file

Action Builder - Remove button

Currently, the transaction builder is only able to add actions and edit actions but not remove actions from the Actions - Widget. We need to add a button to allow actions to be removed. You can play around with the playground HERE .

Action Widget with removable Action

Desktop

Confirmation Modal

RemoveAction

  • Once the user clicks on the Remove - Button from the action component in the Actions - Widget we need an additional user confirmation.
  • User can cancel the removal or confirm removal which will remove the action from the Actions - Widget
  • Figma design specification

REPGuild page - Members button redirection not working

Description:
When on any Guild page user should be able to access the list of all users within that Guild

Steps to Reproduce:

  1. SpinUp Localhost env
  2. Open localhost:3000
  3. Check if Landing Page is loaded
  4. Click on REPGuild box
  5. Click on Members button

Actual behaviour:
Redirected to Landing page

Expected behavior:
User should be redirected to Guilds Members page

Screenshots:
Screenshot 2022-06-29 at 22 16 58

Device Information

  • OS: MacOs
  • Browser GoogleChrome, Brave
  • Device: MacOS Monterey v12.4

Additional context
The same behaviour is for the all Guilds. This is an feature that is not developed or connected, it's not a bug

Vote box index

Description
We seem to be inconsistent about hpw we represent indexes for choices when voting.
On the SC as it currently stands (may change soon):
0: Unused option (don't show ever)
1: First option
2: Second option
...
(Enforced guild always uses last index as against)

We should ensure this happens everywhere, voting for option 1 uses index 1 and shows in the UI as voting for the first option.

Currently when you select option 2 it will vote for option 1 I believe, we just need to make this correct and consistent.
You can check in the block explorer on goerli to see what option is being sent to the contract

Steps to Reproduce
Steps to reproduce the behavior:

  1. Select option 2
  2. Vote
  3. See vote status and option 1 with your votes

Expected behavior
A clear and concise description of what you expected to happen.

Voting option indexes with no metadata

Description
We need to ensure indexes are shown in option labels in both voting box and proposal actions components and that these are always exactly the same.
This will happen when ipfs is loading or breaks and very important for security

Steps to Reproduce
Steps to reproduce the behavior:

  1. Get ipfs to not load correctly
  2. Go to proposal with multiple options and check vote actions and voting box

Expected behavior
These should match

Creating proposal - extra actions appears on proposal page

Description
Given I am creating proposal and I create two actions for proposal, then on Proposal page, I notice that third action has been added automaticallly

Steps to Reproduce

  1. SpinUp Localhost env
  2. Open localhost:3000
  3. Check if Landing Page is loaded  
  4. Click on SWPRuild box
  5. Click on Create Proposal button
  6. Choose Contributer payment
  7. Add two option with actions
  8. Click on Create proposal button
  9. Go to newly created proposal page  

Expected behavior
On Proposal page there should be a number of actions that was added while creating proposal itself

Actual behavior
Third action appears as voting option without being added previoulsy when creating proposal

Screenshots
dxd1
dxd2
dxd3

Device Information
OS: MacOs
Browser GoogleChrome, Brave
Device: MacOS Monterey v12.4

Additional context
This happens when I create proposal in any Guild

Disconnect wallet

Hey guys, I´ve added a Disconnect flow to our connection process. Therefor, we need to add a disconnect button to the Network Modal. You can play around with the connect/disconnect process here! The Network Modal will have two states, Disconnected and Connected:

Connected

Change

Figma design specification

  • Reachable via the account modal by clicking on change can be played around with here!
    -If the user clicks on the Disconnect - Button the modal closes and we change the header to:

disconnected

  • If the user clicks on Connect Wallet - Button we will show him the network modal in the disconnected state:

Connect

Figma design specification

Comments design

We have a basic input component borrowed from proposal creation but we also need some designs around how existing comments will look bellow.

Ideally these should allow for nested conversations and replies that can be automatically minimised. Each of the comments should also be able to react to.

Ideally I think it makes sense to highlight a user's voting power somewhere in the design and if it is an active proposal then which option they voted for also.

Action Builder - Tenderly verification

Guilds are able to do on-chain function calls which we call actions. We are going to use tenderly to simulate the defined actions to check if they are actually executable once a proposal has passed. Please go through the playground before you start working on this issue HERE. To make this step transparent we are gonna add a Verify Action - Modal to the Add Action - Flow:

Verify Action

Verify

  • Always appears once the user clicks on Add Action - Button in the add action process.
  • Anytime a user edits, adds, removes an action we need to verify the whole package of actions via tenderly.
  • The Go to Tenderly - Button is opening up a new tab with the actual tenderly simulation.
  • Figma design specification

Verified

Verified

  • If tenderly's simulation passed successfully, the user can dismiss or close the modal with the close icon.
  • User can still go to tenderly with the Go to tenderly - Button.
  • After clicking dismiss user should see the defined action in the Actions - Widget
  • Figma design specification

Verification Failed

VerificationFailed

  • If tenderly's simulation fails, the user can go back to the action modal, go to tenderly via the Go to tenderly - Button or close the modal with the close icon.
  • We will not allow the user add an action which has not passed the simulation of tenderly.
  • Figma design specification

Set Permissions decode not working

Description
When creating a proposal to set permissions we can see the correct summary line when creating but when decoding on the created proposal page it shows unknown action. We must be decoding incorrectly. It works for transfer just not permissions.

Also test this with other permission types pls

Steps to Reproduce
Steps to reproduce the behavior:

  1. Create a proposal
  2. Add action with set permission for a token
  3. Create proposal
  4. Check proposal page actions

Expected behavior
The summary line in action builder creation should be shown in proposal page as well

Screenshots
Screenshot 2022-06-15 at 11 47 17

Screenshot 2022-06-15 at 11 47 54

Link double slash

In some palces in the UI if going back via browser navigation then clicking links we sometimes see double slashes in the URL breaking the app.
Maybe we can just check for double slashes and remove, think the issue is from hash router maybe.

Will try to add more details if seen again

Rich contract - Dev script examples

We should add some examples:
Core

  • Transfer using known localhost tokens
  • Permissions setting for said tokens and below generic contract calls
    Generic
  • We can maybe make a call to contracts deployed by the script such as the vesting and nft factories.

The issue is with generic calls, since we need to deploy the contracts first to get the addresses to use in rich contract config usually pulled from ipfs. We can have a check for localhost and if it is found then we generate additional rich contract data for testing.

There may be some we currently use that are not showing properly, in which case a new issue should be opened to fix these

Create Guild button is disabled

Description
Create Guild button is disabled and doesn't respond to a click. User should be able to click on Create Guild button and to be redirected to Create Guild Page

Steps to Reproduce
Steps to reproduce the behavior:

  1. SpinUp Localhost env
  2. Open localhost:3000
  3. Check if Landing Page is loaded
  4. Create Guild button should not be present

Expected behavior
Create Guild button should not be visible on Landing Page

Screenshots
Screenshot 2022-06-27 at 15 40 17

Device Information

  • OS: MacOs
  • Browser GoogleChrome, Brave
  • Device: MacOS Monterey v12.4

Additional context
This button should not be present and atm it redirects to broken page

Remove dxvote code

Since we have forked we dont need a lot of dxvote code. Some may be left to be refactored but otherwise we should just refer back to the dxvote repo

You can click on loading skeletons inside Guilds

Description
When loading a Guild, you can click on loading proposal skeleton and it redirects to:
/guilds/:chainId/:guildAddress/proposal/undefined

Steps to Reproduce
Steps to reproduce the behavior:

  1. Click on a guild
  2. Before it displays the proposals, click on a loading skeleton

Expected behavior
You shouldn't be able to click them, or not be redirected to another page.

Screenshots
Screenshot from 2022-06-09 12-06-58

Screenshot from 2022-06-09 12-07-20

Support proposal search

We have a search component but it does not do anything. For now we can just search against:

  • Proposal title
  • Proposer address
  • Addresses in the to field of actions

Likely we can just reuse dxvote's search engine

Action Builder - Show to address in call details

It would be useful to show the to value of each of these calls also (the address). This should be outside of the function call data at the top level of the detailed/technical action view
Screenshot 2022-04-29 at 10 19 53

In addition we should also show value (native token transfer) for visibility only if it is > 0

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.