Skip to content

Commit 43a3462

Browse files
committed
Fix warnings and USD calculation
1 parent 207f797 commit 43a3462

File tree

13 files changed

+16
-16
lines changed

13 files changed

+16
-16
lines changed

components/AmountInCurrency.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,7 @@ const calculatedAmount = computed(() => {
9292
tiaExchange = finalAmount.amount.value
9393
}
9494
95-
let amountConverted = tiaExchange * currentPrice.value.close
95+
let amountConverted = tiaExchange * (currentPrice.value?.close ? currentPrice.value.close : 0)
9696
9797
if (displayCurrency.value === "TIA") {
9898
finalAmount.display.show = {

components/data/BlocksTimeline/BlocksTimelineTable.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -296,7 +296,7 @@ watch(
296296
</td>
297297
<td>
298298
<Flex align="center" gap="4">
299-
<AmountInCurrency :amount="{ value: block.stats.fee, decimal: 6 }" :styles="{ amount: { size: 13 } }" />
299+
<AmountInCurrency :amount="{ value: block.stats.fee, decimal: 6 }" :styles="{ amount: { size: '13' } }" />
300300
</Flex>
301301
</td>
302302
</tr>

components/modules/address/AddressOverview.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -614,7 +614,7 @@ const handleOpenQRModal = () => {
614614
>
615615
<Flex direction="column" gap="8">
616616
<Text size="12" weight="600" color="secondary">Total Balance</Text>
617-
<AmountInCurrency :amount="{ value: totalBalance }" :styles="{ amount: { size: 13 }, currency: { size: 13, color: 'primary' } }" />
617+
<AmountInCurrency :amount="{ value: totalBalance }" :styles="{ amount: { size: '13' }, currency: { size: '13', color: 'primary' } }" />
618618
<!-- <Text size="13" weight="600" color="primary" selectable>{{ tia(totalBalance).toLocaleString('en-US') }} TIA</Text> -->
619619
</Flex>
620620

components/modules/address/tables/DelegationsTable.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ const props = defineProps({
3333
</td>
3434
<td>
3535
<NuxtLink :to="`/validator/${d.validator.id}`">
36-
<AmountInCurrency :amount="{ value: d.amount, decimal: 2 }" :styles="{ amount: { size: 13 }, currency: { size: 13 }}" />
36+
<AmountInCurrency :amount="{ value: d.amount, decimal: 2 }" :styles="{ amount: { size: '13' }, currency: { size: '13' }}" />
3737
</NuxtLink>
3838
</td>
3939
</tr>

components/modules/address/tables/RedelegationsTable.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ const props = defineProps({
4545
</NuxtLink>
4646
</td>
4747
<td>
48-
<AmountInCurrency :amount="{ value: rd.amount, decimal: 2 }" :styles="{ amount: { size: 13 }, currency: { size: 13 }}" />
48+
<AmountInCurrency :amount="{ value: rd.amount, decimal: 2 }" :styles="{ amount: { size: '13' }, currency: { size: '13' }}" />
4949
</td>
5050
<td>
5151
<Flex align="center" :class="$style.link">

components/modules/address/tables/UndelegationsTable.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ const props = defineProps({
4444
</NuxtLink>
4545
</td>
4646
<td>
47-
<AmountInCurrency :amount="{ value: ud.amount, decimal: 2 }" :styles="{ amount: { size: 13 }, currency: { size: 13 }}" />
47+
<AmountInCurrency :amount="{ value: ud.amount, decimal: 2 }" :styles="{ amount: { size: '13' }, currency: { size: '13' }}" />
4848
</td>
4949
<td>
5050
<Flex align="center" :class="$style.link">

components/modules/block/BlockOverview.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -682,7 +682,7 @@ const handleViewRawTransactions = () => {
682682
</td>
683683
<td>
684684
<NuxtLink :to="`/tx/${tx.hash}`">
685-
<AmountInCurrency :amount="{ value: block.stats.fee, decimal: 6 }" :styles="{ amount: { size: 13 }, currency: { size: 13 } }" />
685+
<AmountInCurrency :amount="{ value: block.stats.fee, decimal: 6 }" :styles="{ amount: { size: '13' }, currency: { size: '13' } }" />
686686
</NuxtLink>
687687
</td>
688688
</tr>

components/modules/validator/tables/BlocksTable.vue

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -86,17 +86,17 @@ const props = defineProps({
8686
</td>
8787
<td>
8888
<NuxtLink :to="`/block/${block.height}`">
89-
<AmountInCurrency :amount="{ value: block.stats.fee, decimal: 6 }" :styles="{ amount: { size: 13 }, currency: { size: 13 }}" />
89+
<AmountInCurrency :amount="{ value: block.stats.fee, decimal: 6 }" :styles="{ amount: { size: '13' }, currency: { size: '13' }}" />
9090
</NuxtLink>
9191
</td>
9292
<td>
9393
<NuxtLink :to="`/block/${block.height}`">
94-
<AmountInCurrency :amount="{ value: block.stats.rewards, decimal: 6 }" :styles="{ amount: { size: 13 }, currency: { size: 13 }}" />
94+
<AmountInCurrency :amount="{ value: block.stats.rewards, decimal: 6 }" :styles="{ amount: { size: '13' }, currency: { size: '13' }}" />
9595
</NuxtLink>
9696
</td>
9797
<td>
9898
<NuxtLink :to="`/block/${block.height}`">
99-
<AmountInCurrency :amount="{ value: block.stats.commissions, decimal: 6 }" :styles="{ amount: { size: 13 }, currency: { size: 13 }}" />
99+
<AmountInCurrency :amount="{ value: block.stats.commissions, decimal: 6 }" :styles="{ amount: { size: '13' }, currency: { size: '13' }}" />
100100
</NuxtLink>
101101
</td>
102102
</tr>

components/modules/validator/tables/DelegatorsTable.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ const props = defineProps({
5252
</td>
5353
<td>
5454
<NuxtLink :to="`/address/${d.delegator}`">
55-
<AmountInCurrency :amount="{ value: d.amount, decimal: 2 }" :styles="{ amount: { size: 13 }, currency: { size: 13 }}" />
55+
<AmountInCurrency :amount="{ value: d.amount, decimal: 2 }" :styles="{ amount: { size: '13' }, currency: { size: '13' }}" />
5656
</NuxtLink>
5757
</td>
5858
<td>

pages/addresses.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -192,7 +192,7 @@ const handleLast = async () => {
192192
</td>
193193
<td>
194194
<NuxtLink :to="`/address/${address.hash}`">
195-
<AmountInCurrency :amount="{ value: calculateTotalBalance(address) }" :styles=" {amount: { size: 13 }, currency: { size: 13 } }" />
195+
<AmountInCurrency :amount="{ value: calculateTotalBalance(address) }" :styles=" {amount: { size: '13' }, currency: { size: '13' } }" />
196196
</NuxtLink>
197197
</td>
198198
<td>

0 commit comments

Comments
 (0)