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

Implement top part of token dashboard #623

Merged
merged 15 commits into from
Jun 30, 2023
Merged

Conversation

csillag
Copy link
Contributor

@csillag csillag commented Jun 29, 2023

The token dashboard is what we find when visiting /:network:/:runtime:/token/:address:, for example like this.

This is different from the normal account / contract page. (Although they link to each other.)

The PR implements the top and middle part of the token dashboard. The bottom part (with multiple tabs) is coming later.

Designs:

Also, when displaying info about a contract

  • Properly display creator info (see the design here ) -- test with 0x301879c8677e050f0f7104fe6a3059806Abb41C6
  • If the contract is about a token, link to the relevant token dashboard (see on the above visual) -- test with 0x6Cb9750a92643382e020eA9a170AbB83Df05F30B

@github-actions
Copy link

github-actions bot commented Jun 29, 2023

Deployed to Cloudflare Pages

Latest commit: ddcbbcc4649f98c24c2e6d7b2a97a1631bb45808
Status:✅ Deploy successful!
Preview URL: https://fd2d77ae.oasis-explorer.pages.dev

@csillag csillag force-pushed the csillag/token-dashboard branch 2 times, most recently from 5e3d9ec to 6ae0fd3 Compare June 29, 2023 06:06
@csillag csillag changed the title Implement token dashboard Implement top part of token dashboard Jun 29, 2023
@csillag csillag marked this pull request as ready for review June 29, 2023 06:12
@csillag csillag requested review from buberdds and lukaw3d June 29, 2023 06:12
@csillag
Copy link
Contributor Author

csillag commented Jun 29, 2023

@donouwens says:

This is correct

There will be some updates, but what we have is already worth reviewing.

@csillag csillag force-pushed the csillag/token-dashboard branch 3 times, most recently from 45f8361 to e1e7ed4 Compare June 29, 2023 15:00
@lubej
Copy link
Collaborator

lubej commented Jun 29, 2023

Visual wise header looks a bit off:
image

Copy link
Collaborator

@lubej lubej left a comment

Choose a reason for hiding this comment

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

LGTM overall

src/app/pages/TokenDashboardPage/index.tsx Show resolved Hide resolved
src/app/pages/TokenDashboardPage/TokenTypeCard.tsx Outdated Show resolved Hide resolved
src/app/pages/TokenDashboardPage/TokenTitleCard.tsx Outdated Show resolved Hide resolved
src/app/pages/TokenDashboardPage/TokenSupplyCard.tsx Outdated Show resolved Hide resolved
src/app/pages/TokenDashboardPage/TokenSnapshot.tsx Outdated Show resolved Hide resolved
src/app/pages/TokenDashboardPage/TokenDetailsCard.tsx Outdated Show resolved Hide resolved
@csillag csillag force-pushed the csillag/token-dashboard branch from e1e7ed4 to 941692e Compare June 29, 2023 21:48
@csillag
Copy link
Contributor Author

csillag commented Jun 29, 2023

Visual wise header looks a bit off:

Right. Fixed (?):
image

@csillag csillag requested review from lubej and lukaw3d June 29, 2023 22:02
src/oasis-indexer/api.ts Outdated Show resolved Hide resolved
src/app/pages/TokenDashboardPage/TokenDetailsCard.tsx Outdated Show resolved Hide resolved
@csillag csillag force-pushed the csillag/token-dashboard branch 7 times, most recently from b27ec14 to 9e00cc0 Compare June 30, 2023 01:00
@csillag csillag requested a review from lukaw3d June 30, 2023 01:06
@csillag csillag force-pushed the csillag/token-dashboard branch from 1a44550 to a1e4606 Compare June 30, 2023 08:46
@csillag
Copy link
Contributor Author

csillag commented Jun 30, 2023

Visual wise header looks a bit off:

Finally fixed properly:

image

@csillag csillag force-pushed the csillag/token-dashboard branch 2 times, most recently from 3d223d1 to 40c8381 Compare June 30, 2023 10:04
}) => {
return (
<StyledCard>
<CardHeader component="h5" title={title} sx={{ pb: 0, pl: 4, pt: 4 }} />
<StyledCardContent withContentPadding={withContentPadding}>{children}</StyledCardContent>
{(badge || label) && (
{(badge || label || withConstantHeight) && (
Copy link
Contributor Author

Choose a reason for hiding this comment

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

This solves this issue:
image

@csillag csillag force-pushed the csillag/token-dashboard branch from 40c8381 to 6287ffe Compare June 30, 2023 10:08
(But disable it for now, since we are lacking the required information)
@csillag
Copy link
Contributor Author

csillag commented Jun 30, 2023

@donouwens approves the latest iteration of UI tweaks.

@csillag csillag force-pushed the csillag/token-dashboard branch from ddcbbcc to 791dce3 Compare June 30, 2023 12:27
@csillag csillag merged commit 9227d9a into master Jun 30, 2023
@csillag
Copy link
Contributor Author

csillag commented Jul 4, 2023

Apparently there was some mishap here around the various commits, because it looks the the version merged is not actually the final version; probably some commits were accidentally dropped as part of a force-push. Probably nothing major, just some small cleanups. Still looking.

@csillag
Copy link
Contributor Author

csillag commented Jul 4, 2023

Guys, can you help me running some some analysis what happened here?

Specifically, I'm looking at these events:
image

In detail:

  • The first event says that I have force-pushed this branch from ddcbbcc to 791dce3. This (the second one) is actually the final version.
  • Then there is the approval
  • Then there is the merge commit: 9227d9a

Now, of you look at the merge commit, it has this:
image

The first parent is the last commit on the master branch, and the second parent comes from this branch. But it is not the last commit; it the one that have been superseeded and overwritten by the first event. (You can see the git commit hashes.) So basically, even though I have pushed the latest stuff, what has been merged is not the latest stuff, but the previous one.

How is that even possible?

@csillag
Copy link
Contributor Author

csillag commented Jul 4, 2023

I have restored the only missing change in #655, but I still don't understand what happend, and as a result, have lost a bit of trust in GitHub.

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.

3 participants