Skip to content

Commit

Permalink
Merge pull request #2366 from dusk-network/feature-2363
Browse files Browse the repository at this point in the history
explorer: update display value for current and pending stake
  • Loading branch information
deuch13 authored Sep 12, 2024
2 parents d7c1f4c + 1b4c8f6 commit f211234
Show file tree
Hide file tree
Showing 7 changed files with 316 additions and 174 deletions.
2 changes: 2 additions & 0 deletions explorer/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
- Add accessible name to the gas used progress bar [#2037]
- Add accessible name to the nav bar button on mobile [#2036]
- Implement warning for stale market data [#1892]
- Add tooltip to current and pending stake showing the exact amount [#2363]

### Changed

Expand Down Expand Up @@ -61,6 +62,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
[#2159]: https://github.com/dusk-network/rusk/issues/2159
[#2220]: https://github.com/dusk-network/rusk/issues/2220
[#2348]: https://github.com/dusk-network/rusk/issues/2348
[#2363]: https://github.com/dusk-network/rusk/issues/2363

<!-- VERSIONS -->

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,12 +27,14 @@ exports[`StatisticsPanel > should render the StatisticsPanel, query for the nece
</svg>
<span>
- - -
</span>
<div>
<span>
- - -
</span>
</div>
</div>
<span
Expand All @@ -58,12 +60,14 @@ exports[`StatisticsPanel > should render the StatisticsPanel, query for the nece
</svg>
<span>
- - -
</span>
<div>
<span>
- - -
</span>
</div>
</div>
<span
Expand All @@ -79,6 +83,10 @@ exports[`StatisticsPanel > should render the StatisticsPanel, query for the nece
>
<div
class="statistics-panel__statistics-item"
data-tooltip-id="main-tooltip"
data-tooltip-place="top"
data-tooltip-text="--- DUSK"
data-tooltip-type="info"
>
<div
class="statistics-panel__statistics-item-value"
Expand All @@ -94,11 +102,13 @@ exports[`StatisticsPanel > should render the StatisticsPanel, query for the nece
</svg>
<span>
- - -
</span>
<div>
<span>
- - -
</span>
</div>
</div>
<span
Expand All @@ -109,6 +119,10 @@ exports[`StatisticsPanel > should render the StatisticsPanel, query for the nece
</div>
<div
class="statistics-panel__statistics-item"
data-tooltip-id="main-tooltip"
data-tooltip-place="top"
data-tooltip-text="--- DUSK"
data-tooltip-type="info"
>
<div
class="statistics-panel__statistics-item-value"
Expand All @@ -124,11 +138,13 @@ exports[`StatisticsPanel > should render the StatisticsPanel, query for the nece
</svg>
<span>
- - -
</span>
<div>
<span>
- - -
</span>
</div>
</div>
<span
Expand Down Expand Up @@ -159,11 +175,13 @@ exports[`StatisticsPanel > should render the StatisticsPanel, query for the nece
</svg>
<span>
- - -
</span>
<div>
<span>
- - -
</span>
</div>
</div>
<span
Expand All @@ -189,11 +207,13 @@ exports[`StatisticsPanel > should render the StatisticsPanel, query for the nece
</svg>
<span>
- - -
</span>
<div>
<span>
- - -
</span>
</div>
</div>
<span
Expand Down Expand Up @@ -224,11 +244,13 @@ exports[`StatisticsPanel > should render the StatisticsPanel, query for the nece
</svg>
<span>
- - -
</span>
<div>
<span>
- - -
</span>
</div>
</div>
<span
Expand All @@ -254,11 +276,13 @@ exports[`StatisticsPanel > should render the StatisticsPanel, query for the nece
</svg>
<span>
- - -
</span>
<div>
<span>
- - -
</span>
</div>
</div>
<span
Expand Down Expand Up @@ -1032,11 +1056,13 @@ exports[`StatisticsPanel > should render the StatisticsPanel, query for the nece
</svg>
0.368
<div>
0.368
</div>
</div>
<span
Expand All @@ -1062,11 +1088,13 @@ exports[`StatisticsPanel > should render the StatisticsPanel, query for the nece
</svg>
168M
<div>
168.00M
</div>
</div>
<span
Expand All @@ -1082,6 +1110,10 @@ exports[`StatisticsPanel > should render the StatisticsPanel, query for the nece
>
<div
class="statistics-panel__statistics-item"
data-tooltip-id="main-tooltip"
data-tooltip-place="top"
data-tooltip-text="58226174.026663415 DUSK"
data-tooltip-type="info"
>
<div
class="statistics-panel__statistics-item-value"
Expand All @@ -1097,10 +1129,14 @@ exports[`StatisticsPanel > should render the StatisticsPanel, query for the nece
</svg>
58.2M
<div
class="approximate"
>
58.23M
</div>
</div>
<span
Expand All @@ -1111,6 +1147,10 @@ exports[`StatisticsPanel > should render the StatisticsPanel, query for the nece
</div>
<div
class="statistics-panel__statistics-item"
data-tooltip-id="main-tooltip"
data-tooltip-place="top"
data-tooltip-text="2573278.3297094363 DUSK"
data-tooltip-type="info"
>
<div
class="statistics-panel__statistics-item-value"
Expand All @@ -1126,10 +1166,14 @@ exports[`StatisticsPanel > should render the StatisticsPanel, query for the nece
</svg>
2.6M
<div
class="approximate"
>
2.57M
</div>
</div>
<span
Expand Down Expand Up @@ -1160,10 +1204,12 @@ exports[`StatisticsPanel > should render the StatisticsPanel, query for the nece
</svg>
487,596
<div>
487,596
</div>
</div>
<span
Expand All @@ -1189,10 +1235,12 @@ exports[`StatisticsPanel > should render the StatisticsPanel, query for the nece
</svg>
10
<div>
10
</div>
</div>
<span
Expand Down Expand Up @@ -1223,10 +1271,12 @@ exports[`StatisticsPanel > should render the StatisticsPanel, query for the nece
</svg>
945
<div>
945
</div>
</div>
<span
Expand All @@ -1252,10 +1302,12 @@ exports[`StatisticsPanel > should render the StatisticsPanel, query for the nece
</svg>
34
<div>
34
</div>
</div>
<span
Expand Down
12 changes: 9 additions & 3 deletions explorer/src/lib/containers/statistics-panel/StatisticsPanel.css
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,15 @@
justify-content: center;
}

.statistics-panel__statistics-item[data-tooltip-id] {
cursor: help;
}

.approximate::before {
display: inline;
content: "~";
}

.statistics-panel__statistics-item::after,
.statistics-panel__statistics-item::before {
content: "";
Expand All @@ -58,9 +67,6 @@
display: flex;
flex-direction: row;
column-gap: 0.3125rem;
}

.statistics-panel__statistics-item-value {
font-weight: 500;
font-size: 1rem;
}
Expand Down
Loading

0 comments on commit f211234

Please sign in to comment.