From a858804c0a27a7282b67cc050c7dc86db0521deb Mon Sep 17 00:00:00 2001 From: kurt Date: Wed, 2 Oct 2024 14:49:19 +0800 Subject: [PATCH] fix format --- src/pages/resources/components/forms/powerup.svelte | 5 +++-- src/pages/resources/components/state/prices.svelte | 10 ++++++---- 2 files changed, 9 insertions(+), 6 deletions(-) diff --git a/src/pages/resources/components/forms/powerup.svelte b/src/pages/resources/components/forms/powerup.svelte index 3d8141c7..b34633d5 100644 --- a/src/pages/resources/components/forms/powerup.svelte +++ b/src/pages/resources/components/forms/powerup.svelte @@ -10,7 +10,8 @@ import {systemToken} from '~/stores/tokens' import {systemTokenBalance} from '~/stores/balances' import { - cpuPowerupPrice as powerupPrice, + cpuPowerupPrice, + netPowerupPrice, sampleUsage, statePowerUp, } from '~/pages/resources/resources' @@ -27,7 +28,7 @@ export let resource: string = 'cpu' const unit = resource === 'cpu' ? 'ms' : 'kb' - // const powerupPrice = resource === 'cpu' ? cpuPowerupPrice : netPowerupPrice + const powerupPrice = resource === 'cpu' ? cpuPowerupPrice : netPowerupPrice let amount: Writable = writable('') let error: string | undefined diff --git a/src/pages/resources/components/state/prices.svelte b/src/pages/resources/components/state/prices.svelte index c26afa72..909a2597 100644 --- a/src/pages/resources/components/state/prices.svelte +++ b/src/pages/resources/components/state/prices.svelte @@ -6,9 +6,11 @@ import {activeBlockchain} from '~/store' import { - cpuPowerupPrice as powerupPrice, + cpuPowerupPrice, + netPowerupPrice, rexPrice, - cpuStakingPrice as stakingPrice, + cpuStakingPrice, + netStakingPrice, } from '~/pages/resources/resources' import Button from '~/components/elements/button.svelte' @@ -17,8 +19,8 @@ export let resource = 'cpu' const unit = resource === 'cpu' ? 'ms' : 'kb' - // const powerupPrice = resource === 'cpu' ? cpuPowerupPrice : netPowerupPrice - // const stakingPrice = resource === 'cpu' ? cpuStakingPrice : netStakingPrice + const powerupPrice = resource === 'cpu' ? cpuPowerupPrice : netPowerupPrice + const stakingPrice = resource === 'cpu' ? cpuStakingPrice : netStakingPrice const {PowerUp, REX, Staking} = ChainFeatures