Git Product home page Git Product logo

ic-rocks's Introduction

ic-rocks

UI for ic.rocks.

Uses Next.js, react-query, and tailwind.

Environment Variables

Create a .env file:

//API_ENDPOINT = http://localhost:3001 // If specified, will override the default API endpoint.

Development

npm run dev

Building and Running

npm run build
npm start

ic-rocks's People

Contributors

floorlamp avatar ggreif avatar matthewhammer avatar njolipatrick avatar tarek-eg avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

ic-rocks's Issues

Display NFT ownership data

#25 will give us token transaction history, but we still need a table that shows current ownership. We should also display asset previews if possible.

Token ID Preview Owner
1 ๐Ÿ˜„ alice
2 ๐Ÿ˜ฆ bob
3 ๐Ÿ˜ -

This table should be in a different tab, perhaps called "Token Owners".

Parallelize canister syncing job

Right now, we are running syncing all canisters for all subnets sequentially. We can improve this and sync 5-10 subnets in parallel, in order to have fresher data.

Add table of neurons grouped by dissolve delay

Create a new table or page showing a count of neurons broken down like this:

Dissolving Non-dissolving
<6 mo 100 200
6mo - 1yr 100 200
1yr - 2yr 100 200
2yr - 3yr 100 200
3yr - 4yr 100 200
4yr - 8yr 100 200

A new API endpoint will need to be added here. All required data should be available for querying and grouping.

Associate neurons IDs with account IDs

  1. Identify all accounts that contain one or more minting events.
  2. Match total ICP in neurons with total ICP in those accounts with minting events
  3. Verify match by comparing the neuron Created date with the date of the oldest transaction in the account. The date / time stamp should be within a small tolerance. It would be acceptable to use 5 minutes even though the difference is likely less than 15 sec most of the time.)
  4. For all matches, update the neuron information with the associated account number

Notes:
Some neuron IDs will not be associated with account IDs using this method, but it should be a way to identify 90% of the unassociated neuron account IDs. This method requires that the amount of ICP in the accounts and neurons are unique at the time of analysis and that the neuron account has a minting event. It would be good to run this analysis periodically to increase the hit rate for matches.

There are 3 events that mint ICP by the NNS governance cannister: 1) genesis, 2) node provider payments, 3) voting rewards. Genesis minting happened on May 10, 2021. Node provider payments happen every month and the accounts and neurons that hold those ICP will be identified using this method. Voting rewards are minted every time a neuron owner chooses to either Spawn Neuron or Merge Maturity. Spawn Neuron is an action that creates a new locked neuron with the minted ICP and a 7 day dissolve delay. This action can be performed any time the maturity in the parent neuron represents 1 ICP or more. Once the owner dissolves the child neuron, then ICP can be dispersed into any account of the owner's choice. Merge Maturity is an action that allows the neuron owner to mint ICP directly into the parent neuron account. This action can be performed daily. The ability to Merge Maturity was enabled on Sept 6, 2021.

Add columns to Genesis Accounts page

On the Neurons tab, under Genesis Accounts, add two new columns titled Total Neurons and High DD. Display the total number of neurons in each Genesis Account in the Total Neurons column. Display the total number of neurons in each Genesis Account with a dissolve delay greater than 4 years in the High DD column.

It is ok to reduce the width of the Account column. It is also ok to remove the Next Dissolve Date column if necessary.

Change the ICP column title to Total ICP.

The High DD metric is a signal of long term commitment from seed investors to the IC. All genesis neurons were originally configured with 4 years or less dissolve delay, so any neuron with dissolve delay higher than 4 years can only occur if the neuron owner intentionally increased the dissolve delay.

Add chart showing ICP inflation

The current ICP mint and burn charts show absolute changes. We should have a chart showing inflation (mints - burns) that show both absolute numbers and the % change to total supply, for better measuring inflation or deflation.

One approach is to have one chart with 2 y-axes, absolute ICP on left, % change on right. This may require tweaking of the Chart component

Current transactions endpoints: https://github.com/ic-rocks/api/blob/main/routes/transactions.ts
Chart config: https://github.com/ic-rocks/ic-rocks/blob/main/components/ChartsPages/ChartIds.tsx
Hooks that fetch chart data: https://github.com/ic-rocks/ic-rocks/blob/main/lib/hooks/useTransactionCounts.ts

Add Plug support

Plug is not supported since our custom API authentication uses the identity to sign a message, which Plug does not support yet.

When Plug adds arbitrary signatures, it should added as an authentication method.

Identify original funding sources for neurons

Develop a forensic tool that can query neuron accounts for funding sources for that neuron. When an neuron ID is entered, display all the accounts and sum of ICP that were used to fund that neuron sorted from highest to lowest ICP amount. When a user selects an account in the list, expand to show all transactions that funded the neuron from that account sorted from highest to lowest ICP amount. When a user selects a specific transaction, show all accounts and total ICP that made deposits to that account prior to the transaction sorted from highest to lowest ICP amount. When a user selects an account in the list, expand to show all transactions that funded the account sorted from highest to lowest. Continue this pattern as many times as needed by the user. Allow the user to tag each account they consider to be the funding sources for the neuron. Enable quick return to the original neuron level and indicate what forensic path has already been followed in that session.

Note: It may be best to enable this functionality to users who are logged in to ic rocks. Different people will reach different conclusions as to what accounts originally funded the neuron, so it might make more sense for this to be a custom query with user specific results.

Transaction and account scroll improvement

Currently it is possible to scroll one page at a time or go to end or begin on the transactions and the accounts pages. Add an option for the user to go to a specific page number directly.

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.