diff --git a/explorer/CHANGELOG.md b/explorer/CHANGELOG.md index 396d18d0de..e2f604fa69 100644 --- a/explorer/CHANGELOG.md +++ b/explorer/CHANGELOG.md @@ -10,12 +10,21 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ### Added - Show the error message for failed transactions [#2220] +- Add tooltip to current and pending stake showing the exact amount [#2363] +- Add `memo` and `isDeploy` fields in transactions [#2362] +- Add `txType` fields in transactions and display it [#2347] +- Add `json` payload to block detail [#2364] ### Changed +- Switch `raw` payload with `json` in transaction details [#2364] +- Change the displayed value for average gas price to lux [#2416] +- Change the blocks table header `FEE` to `GAS` and `AVG` to `AVG PRICE` and `TOTAL` to `USED` [#2416] + ### Fixed - Fix Transactions Fee is not properly computed [#2348] +- Fix shield icons used for tx type [#2389] ## [0.2.0] - 2024-08-26 @@ -26,10 +35,6 @@ 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] -- Add `memo` and `isDeploy` fields in transactions [#2362] -- Add `txType` fields in transactions and display it [#2347] -- Add `json` payload to block detail [#2364] ### Changed @@ -37,13 +42,11 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - Update Statistics Panel labels for clarity [#2034] - Update font-display to swap for custom fonts to improve performance [#2025] - Optimize auto re-renders of relative times [#2059] -- Switch `raw` payload with `json` in transaction details [#2364] ### Fixed - Fix Average Fee Paid label [#2057] - Fix list items alignment on mobile [#2056] -- Fix shield icons used for tx type [#2389] ## [0.1.0] - 2024-07-24 diff --git a/explorer/src/lib/chain-info/__tests__/transformBlock.spec.js b/explorer/src/lib/chain-info/__tests__/transformBlock.spec.js index a2fa85063f..a9440f3a30 100644 --- a/explorer/src/lib/chain-info/__tests__/transformBlock.spec.js +++ b/explorer/src/lib/chain-info/__tests__/transformBlock.spec.js @@ -57,7 +57,11 @@ describe("transformBlock", () => { txtype: "Phoenix", }, ], - stats: { averageGasPrice: 1, gasLimit: 5000000000, gasUsed: 580718 }, + stats: { + averageGasPrice: 1, + gasLimit: 5000000000, + gasUsed: 580718, + }, }, }; diff --git a/explorer/src/lib/components/__tests__/__snapshots__/BlockDetails.spec.js.snap b/explorer/src/lib/components/__tests__/__snapshots__/BlockDetails.spec.js.snap index ba8cb1daa6..12bac2fce8 100644 --- a/explorer/src/lib/components/__tests__/__snapshots__/BlockDetails.spec.js.snap +++ b/explorer/src/lib/components/__tests__/__snapshots__/BlockDetails.spec.js.snap @@ -352,8 +352,7 @@ exports[`Block Details > it renders the Block Details component with the payload
- 0.000000001 - DUSK + 1
renders the Block Details component 1`] = `
- 0.000000001 - DUSK + 1
should disable the \`Show More\` button if there is no mo - Fee (Dusk) + Gas @@ -104,7 +104,7 @@ exports[`Blocks Card > should disable the \`Show More\` button if there is no mo - AVG: + AVG PRICE: 0 @@ -113,7 +113,7 @@ exports[`Blocks Card > should disable the \`Show More\` button if there is no mo - TOTAL: + USED: 0 @@ -164,7 +164,7 @@ exports[`Blocks Card > should disable the \`Show More\` button if there is no mo - AVG: + AVG PRICE: 0 @@ -173,7 +173,7 @@ exports[`Blocks Card > should disable the \`Show More\` button if there is no mo - TOTAL: + USED: 0 @@ -224,7 +224,7 @@ exports[`Blocks Card > should disable the \`Show More\` button if there is no mo - AVG: + AVG PRICE: 0 @@ -233,7 +233,7 @@ exports[`Blocks Card > should disable the \`Show More\` button if there is no mo - TOTAL: + USED: 0 @@ -284,7 +284,7 @@ exports[`Blocks Card > should disable the \`Show More\` button if there is no mo - AVG: + AVG PRICE: 0 @@ -293,7 +293,7 @@ exports[`Blocks Card > should disable the \`Show More\` button if there is no mo - TOTAL: + USED: 0 @@ -344,7 +344,7 @@ exports[`Blocks Card > should disable the \`Show More\` button if there is no mo - AVG: + AVG PRICE: 0 @@ -353,7 +353,7 @@ exports[`Blocks Card > should disable the \`Show More\` button if there is no mo - TOTAL: + USED: 0 @@ -404,7 +404,7 @@ exports[`Blocks Card > should disable the \`Show More\` button if there is no mo - AVG: + AVG PRICE: 0 @@ -413,7 +413,7 @@ exports[`Blocks Card > should disable the \`Show More\` button if there is no mo - TOTAL: + USED: 0 @@ -464,7 +464,7 @@ exports[`Blocks Card > should disable the \`Show More\` button if there is no mo - AVG: + AVG PRICE: 0 @@ -473,7 +473,7 @@ exports[`Blocks Card > should disable the \`Show More\` button if there is no mo - TOTAL: + USED: 0 @@ -524,7 +524,7 @@ exports[`Blocks Card > should disable the \`Show More\` button if there is no mo - AVG: + AVG PRICE: 0 @@ -533,7 +533,7 @@ exports[`Blocks Card > should disable the \`Show More\` button if there is no mo - TOTAL: + USED: 0 @@ -584,7 +584,7 @@ exports[`Blocks Card > should disable the \`Show More\` button if there is no mo - AVG: + AVG PRICE: 0 @@ -593,7 +593,7 @@ exports[`Blocks Card > should disable the \`Show More\` button if there is no mo - TOTAL: + USED: 0 @@ -644,7 +644,7 @@ exports[`Blocks Card > should disable the \`Show More\` button if there is no mo - AVG: + AVG PRICE: 0 @@ -653,7 +653,7 @@ exports[`Blocks Card > should disable the \`Show More\` button if there is no mo - TOTAL: + USED: 0 diff --git a/explorer/src/lib/components/__tests__/__snapshots__/BlocksList.spec.js.snap b/explorer/src/lib/components/__tests__/__snapshots__/BlocksList.spec.js.snap index 08e098b815..07910e977d 100644 --- a/explorer/src/lib/components/__tests__/__snapshots__/BlocksList.spec.js.snap +++ b/explorer/src/lib/components/__tests__/__snapshots__/BlocksList.spec.js.snap @@ -63,8 +63,7 @@ exports[`Blocks List > renders the Blocks List component 1`] = `
- 0.000000001 - DUSK + 1
should render the \`BlocksTable\` component 1`] = ` - Fee (Dusk) + Gas @@ -75,7 +75,7 @@ exports[`Blocks Table > should render the \`BlocksTable\` component 1`] = ` - AVG: + AVG PRICE: 0 @@ -84,7 +84,7 @@ exports[`Blocks Table > should render the \`BlocksTable\` component 1`] = ` - TOTAL: + USED: 0 @@ -135,7 +135,7 @@ exports[`Blocks Table > should render the \`BlocksTable\` component 1`] = ` - AVG: + AVG PRICE: 0 @@ -144,7 +144,7 @@ exports[`Blocks Table > should render the \`BlocksTable\` component 1`] = ` - TOTAL: + USED: 0 @@ -195,7 +195,7 @@ exports[`Blocks Table > should render the \`BlocksTable\` component 1`] = ` - AVG: + AVG PRICE: 0 @@ -204,7 +204,7 @@ exports[`Blocks Table > should render the \`BlocksTable\` component 1`] = ` - TOTAL: + USED: 0 @@ -255,7 +255,7 @@ exports[`Blocks Table > should render the \`BlocksTable\` component 1`] = ` - AVG: + AVG PRICE: 0 @@ -264,7 +264,7 @@ exports[`Blocks Table > should render the \`BlocksTable\` component 1`] = ` - TOTAL: + USED: 0 @@ -315,7 +315,7 @@ exports[`Blocks Table > should render the \`BlocksTable\` component 1`] = ` - AVG: + AVG PRICE: 0 @@ -324,7 +324,7 @@ exports[`Blocks Table > should render the \`BlocksTable\` component 1`] = ` - TOTAL: + USED: 0 @@ -375,7 +375,7 @@ exports[`Blocks Table > should render the \`BlocksTable\` component 1`] = ` - AVG: + AVG PRICE: 0 @@ -384,7 +384,7 @@ exports[`Blocks Table > should render the \`BlocksTable\` component 1`] = ` - TOTAL: + USED: 0 @@ -435,7 +435,7 @@ exports[`Blocks Table > should render the \`BlocksTable\` component 1`] = ` - AVG: + AVG PRICE: 0 @@ -444,7 +444,7 @@ exports[`Blocks Table > should render the \`BlocksTable\` component 1`] = ` - TOTAL: + USED: 0 @@ -495,7 +495,7 @@ exports[`Blocks Table > should render the \`BlocksTable\` component 1`] = ` - AVG: + AVG PRICE: 0 @@ -504,7 +504,7 @@ exports[`Blocks Table > should render the \`BlocksTable\` component 1`] = ` - TOTAL: + USED: 0 @@ -555,7 +555,7 @@ exports[`Blocks Table > should render the \`BlocksTable\` component 1`] = ` - AVG: + AVG PRICE: 0 @@ -564,7 +564,7 @@ exports[`Blocks Table > should render the \`BlocksTable\` component 1`] = ` - TOTAL: + USED: 0 @@ -615,7 +615,7 @@ exports[`Blocks Table > should render the \`BlocksTable\` component 1`] = ` - AVG: + AVG PRICE: 0 @@ -624,7 +624,7 @@ exports[`Blocks Table > should render the \`BlocksTable\` component 1`] = ` - TOTAL: + USED: 0 diff --git a/explorer/src/lib/components/block-details/BlockDetails.svelte b/explorer/src/lib/components/block-details/BlockDetails.svelte index abd57e909f..eef94113a5 100644 --- a/explorer/src/lib/components/block-details/BlockDetails.svelte +++ b/explorer/src/lib/components/block-details/BlockDetails.svelte @@ -169,7 +169,7 @@ > average gas price {formatter(luxToDusk(data.transactions.stats.averageGasPrice))} DUSK{formatter(data.transactions.stats.averageGasPrice)} diff --git a/explorer/src/lib/components/blocks-list/BlocksList.svelte b/explorer/src/lib/components/blocks-list/BlocksList.svelte index 58260eddfa..d0f6b466c7 100644 --- a/explorer/src/lib/components/blocks-list/BlocksList.svelte +++ b/explorer/src/lib/components/blocks-list/BlocksList.svelte @@ -59,7 +59,7 @@ > average gas price - {formatter(luxToDusk(data.transactions.stats.averageGasPrice))} DUSK + {formatter(data.transactions.stats.averageGasPrice)} diff --git a/explorer/src/lib/components/blocks-table/BlocksTable.svelte b/explorer/src/lib/components/blocks-table/BlocksTable.svelte index 46c03df996..2983e097cd 100644 --- a/explorer/src/lib/components/blocks-table/BlocksTable.svelte +++ b/explorer/src/lib/components/blocks-table/BlocksTable.svelte @@ -31,7 +31,7 @@ Block - Fee (Dusk) + Gas Txn(s) Rewards (Dusk) @@ -48,9 +48,9 @@ - AVG: + AVG PRICE: {numberFormatter(block.transactions.stats.averageGasPrice)}
- TOTAL: + USED: {numberFormatter(block.transactions.stats.gasUsed)}
{numberFormatter(block.transactions.data.length)} diff --git a/explorer/src/routes/blocks/__tests__/__snapshots__/page.spec.js.snap b/explorer/src/routes/blocks/__tests__/__snapshots__/page.spec.js.snap index c6e52fd2d5..9e727e1c10 100644 --- a/explorer/src/routes/blocks/__tests__/__snapshots__/page.spec.js.snap +++ b/explorer/src/routes/blocks/__tests__/__snapshots__/page.spec.js.snap @@ -99,7 +99,6 @@ exports[`Blocks page > should render the Blocks page with the mobile layout 1`] class="details-list__definition details-list__definition--table" > 0 - DUSK
should render the Blocks page with the mobile layout 1`] class="details-list__definition details-list__definition--table" > 0 - DUSK
should render the Blocks page with the mobile layout 1`] class="details-list__definition details-list__definition--table" > 0 - DUSK
should render the Blocks page with the mobile layout 1`] class="details-list__definition details-list__definition--table" > 0 - DUSK
should render the Blocks page with the mobile layout 1`] class="details-list__definition details-list__definition--table" > 0 - DUSK
should render the Blocks page with the mobile layout 1`] class="details-list__definition details-list__definition--table" > 0 - DUSK
should render the Blocks page with the mobile layout 1`] class="details-list__definition details-list__definition--table" > 0 - DUSK
should render the Blocks page with the mobile layout 1`] class="details-list__definition details-list__definition--table" > 0 - DUSK
should render the Blocks page with the mobile layout 1`] class="details-list__definition details-list__definition--table" > 0 - DUSK
should render the Blocks page with the mobile layout 1`] class="details-list__definition details-list__definition--table" > 0 - DUSK
should render the Blocks page with the mobile layout 1`] class="details-list__definition details-list__definition--table" > 0 - DUSK
should render the Blocks page with the mobile layout 1`] class="details-list__definition details-list__definition--table" > 0 - DUSK
should render the Blocks page with the mobile layout 1`] class="details-list__definition details-list__definition--table" > 0 - DUSK
should render the Blocks page with the mobile layout 1`] class="details-list__definition details-list__definition--table" > 0 - DUSK
should render the Blocks page with the mobile layout 1`] class="details-list__definition details-list__definition--table" > 0 - DUSK
should render the Blocks page, start polling for blocks a - Fee (Dusk) + Gas @@ -2117,7 +2102,7 @@ exports[`Blocks page > should render the Blocks page, start polling for blocks a - AVG: + AVG PRICE: 0 @@ -2126,7 +2111,7 @@ exports[`Blocks page > should render the Blocks page, start polling for blocks a - TOTAL: + USED: 0 @@ -2177,7 +2162,7 @@ exports[`Blocks page > should render the Blocks page, start polling for blocks a - AVG: + AVG PRICE: 0 @@ -2186,7 +2171,7 @@ exports[`Blocks page > should render the Blocks page, start polling for blocks a - TOTAL: + USED: 0 @@ -2237,7 +2222,7 @@ exports[`Blocks page > should render the Blocks page, start polling for blocks a - AVG: + AVG PRICE: 0 @@ -2246,7 +2231,7 @@ exports[`Blocks page > should render the Blocks page, start polling for blocks a - TOTAL: + USED: 0 @@ -2297,7 +2282,7 @@ exports[`Blocks page > should render the Blocks page, start polling for blocks a - AVG: + AVG PRICE: 0 @@ -2306,7 +2291,7 @@ exports[`Blocks page > should render the Blocks page, start polling for blocks a - TOTAL: + USED: 0 @@ -2357,7 +2342,7 @@ exports[`Blocks page > should render the Blocks page, start polling for blocks a - AVG: + AVG PRICE: 0 @@ -2366,7 +2351,7 @@ exports[`Blocks page > should render the Blocks page, start polling for blocks a - TOTAL: + USED: 0 @@ -2417,7 +2402,7 @@ exports[`Blocks page > should render the Blocks page, start polling for blocks a - AVG: + AVG PRICE: 0 @@ -2426,7 +2411,7 @@ exports[`Blocks page > should render the Blocks page, start polling for blocks a - TOTAL: + USED: 0 @@ -2477,7 +2462,7 @@ exports[`Blocks page > should render the Blocks page, start polling for blocks a - AVG: + AVG PRICE: 0 @@ -2486,7 +2471,7 @@ exports[`Blocks page > should render the Blocks page, start polling for blocks a - TOTAL: + USED: 0 @@ -2537,7 +2522,7 @@ exports[`Blocks page > should render the Blocks page, start polling for blocks a - AVG: + AVG PRICE: 0 @@ -2546,7 +2531,7 @@ exports[`Blocks page > should render the Blocks page, start polling for blocks a - TOTAL: + USED: 0 @@ -2597,7 +2582,7 @@ exports[`Blocks page > should render the Blocks page, start polling for blocks a - AVG: + AVG PRICE: 0 @@ -2606,7 +2591,7 @@ exports[`Blocks page > should render the Blocks page, start polling for blocks a - TOTAL: + USED: 0 @@ -2657,7 +2642,7 @@ exports[`Blocks page > should render the Blocks page, start polling for blocks a - AVG: + AVG PRICE: 0 @@ -2666,7 +2651,7 @@ exports[`Blocks page > should render the Blocks page, start polling for blocks a - TOTAL: + USED: 0 @@ -2717,7 +2702,7 @@ exports[`Blocks page > should render the Blocks page, start polling for blocks a - AVG: + AVG PRICE: 0 @@ -2726,7 +2711,7 @@ exports[`Blocks page > should render the Blocks page, start polling for blocks a - TOTAL: + USED: 0 @@ -2777,7 +2762,7 @@ exports[`Blocks page > should render the Blocks page, start polling for blocks a - AVG: + AVG PRICE: 0 @@ -2786,7 +2771,7 @@ exports[`Blocks page > should render the Blocks page, start polling for blocks a - TOTAL: + USED: 0 @@ -2837,7 +2822,7 @@ exports[`Blocks page > should render the Blocks page, start polling for blocks a - AVG: + AVG PRICE: 0 @@ -2846,7 +2831,7 @@ exports[`Blocks page > should render the Blocks page, start polling for blocks a - TOTAL: + USED: 0 @@ -2897,7 +2882,7 @@ exports[`Blocks page > should render the Blocks page, start polling for blocks a - AVG: + AVG PRICE: 0 @@ -2906,7 +2891,7 @@ exports[`Blocks page > should render the Blocks page, start polling for blocks a - TOTAL: + USED: 0 @@ -2957,7 +2942,7 @@ exports[`Blocks page > should render the Blocks page, start polling for blocks a - AVG: + AVG PRICE: 0 @@ -2966,7 +2951,7 @@ exports[`Blocks page > should render the Blocks page, start polling for blocks a - TOTAL: + USED: 0 diff --git a/explorer/src/routes/blocks/block/__tests__/__snapshots__/page.spec.js.snap b/explorer/src/routes/blocks/block/__tests__/__snapshots__/page.spec.js.snap index c9277b1fa0..afc38588b3 100644 --- a/explorer/src/routes/blocks/block/__tests__/__snapshots__/page.spec.js.snap +++ b/explorer/src/routes/blocks/block/__tests__/__snapshots__/page.spec.js.snap @@ -430,8 +430,7 @@ exports[`Block Details > should render the Block Details page and query the nece
- 0.000000001 - DUSK + 1
should render the Transaction section of the Block Deta
- 0.000000001 - DUSK + 1