Skip to content

Commit

Permalink
Improve commission tooltip for new validators (#152)
Browse files Browse the repository at this point in the history
* improve tooltip on new validator

* improve test and bump version
  • Loading branch information
Søren Schwartz authored Dec 4, 2023
1 parent afb60d3 commit 6e6317f
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 5 deletions.
2 changes: 1 addition & 1 deletion frontend/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "ccscan-frontend",
"description": "CCDScan frontend",
"version": "1.5.22",
"version": "1.5.23",
"engine": "16",
"type": "module",
"private": true,
Expand Down
11 changes: 7 additions & 4 deletions frontend/src/components/Staking/CommissionRates.vue
Original file line number Diff line number Diff line change
@@ -1,13 +1,16 @@
<template>
<span
<Tooltip
v-if="
props.currentPaydayCommission === undefined ||
props.currentPaydayCommission === null
"
class="numerical"
:text="`Validator is new and rates will be active on next payday.`"
>
{{ `${formatPercentage(props.nextPaydayCommission)}%` }}
</span>
<span class="numerical change">
{{ `${formatPercentage(props.nextPaydayCommission)}%` }}
<WarningIcon class="h-4 align-middle" />
</span>
</Tooltip>
<Tooltip
v-else-if="props.nextPaydayCommission !== props.currentPaydayCommission"
:text="`Rates will change to ${formatPercentage(
Expand Down

0 comments on commit 6e6317f

Please sign in to comment.