File tree Expand file tree Collapse file tree 1 file changed +9
-6
lines changed
packages/neuron-ui/src/components/NervosDAO Expand file tree Collapse file tree 1 file changed +9
-6
lines changed Original file line number Diff line number Diff line change @@ -60,14 +60,17 @@ const WithdrawDialog = ({
60
60
const currentEpochInfo = epochParser ( currentEpoch )
61
61
const targetEpochNumber = calculateTargetEpochNumber ( depositEpochInfo , currentEpochInfo )
62
62
const epochs = targetEpochNumber - currentEpochInfo . number - BigInt ( 1 )
63
- const message = t ( 'nervos-dao.notice-wait-time' , {
64
- epochs : localNumberFormatter ( epochs ) ,
65
- blocks : localNumberFormatter ( currentEpochInfo . length - currentEpochInfo . index ) ,
66
- days : localNumberFormatter ( epochs / BigInt ( 6 ) ) ,
67
- } )
63
+ const message =
64
+ epochs >= BigInt ( 0 )
65
+ ? t ( 'nervos-dao.notice-wait-time' , {
66
+ epochs : localNumberFormatter ( epochs ) ,
67
+ blocks : localNumberFormatter ( currentEpochInfo . length - currentEpochInfo . index ) ,
68
+ days : localNumberFormatter ( epochs / BigInt ( 6 ) ) ,
69
+ } )
70
+ : ''
68
71
69
72
const alert =
70
- epochs <= BigInt ( 5 )
73
+ epochs <= BigInt ( 5 ) && epochs >= BigInt ( 0 )
71
74
? t ( 'nervos-dao.withdraw-alert' , {
72
75
epochs,
73
76
nextLeftEpochs : epochs + BigInt ( 180 ) ,
You can’t perform that action at this time.
0 commit comments