Skip to content

Commit 79548d3

Browse files
committed
Handle celestials and new tvs data format
1 parent f7b99cc commit 79548d3

17 files changed

Lines changed: 62 additions & 54 deletions

File tree

components/AddressBadge.vue

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<script setup>
22
const props = defineProps({
3-
hash: {
4-
type: String,
3+
account: {
4+
type: Object,
55
required: true,
66
},
77
color: {
@@ -13,12 +13,12 @@ const props = defineProps({
1313
const alias = computed(() => {
1414
const { $getDisplayName } = useNuxtApp()
1515
16-
return $getDisplayName('addresses', props.hash)
16+
return $getDisplayName('addresses', "", props.account)
1717
})
1818
</script>
1919

2020
<template>
21-
<NuxtLink :to="`/address/${hash}`" @click.stop>
21+
<NuxtLink :to="`/address/${account.hash}`" @click.stop>
2222
<Flex align="center" gap="6">
2323
<Text size="13" weight="600" :color="color"> {{ alias }} </Text>
2424
</Flex>

components/data/LatestPFBTable.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -106,7 +106,7 @@ isLoading.value = false
106106
<NuxtLink :to="`/tx/${pfb.hash}`">
107107
<Flex align="center" justify="center">
108108
<Text size="12" weight="600" color="primary" class="table_column_alias">
109-
{{ $getDisplayName('addresses', pfb.signers[0]) }}
109+
{{ $getDisplayName('addresses', pfb.signers[0].hash) }}
110110
</Text>
111111
</Flex>
112112
</NuxtLink>

components/modules/address/tables/GrantersTable.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@ const handleViewRawGrants = (g) => {
7373
<td @click="handleViewRawGrants(g)">
7474
<Flex align="center">
7575
<Text size="12" weight="600" color="primary" class="table_column_alias">
76-
{{ $getDisplayName('addresses', g.granter) }}
76+
{{ $getDisplayName('addresses', g.granter.hash) }}
7777
</Text>
7878
</Flex>
7979
</td>

components/modules/address/tables/GrantsTable.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@ const handleViewRawGrants = (g) => {
7373
<td @click="handleViewRawGrants(g)">
7474
<Flex align="center">
7575
<Text size="12" weight="600" color="primary" class="table_column_alias">
76-
{{ $getDisplayName('addresses', g.grantee) }}
76+
{{ $getDisplayName('addresses', g.grantee.hash) }}
7777
</Text>
7878
</Flex>
7979
</td>

components/modules/block/BlobsTable.vue

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -106,7 +106,7 @@ const handleViewBlob = (blob) => {
106106
namespace_name: blob.namespace.name,
107107
commitment: blob.commitment,
108108
height: blob.height,
109-
signer: blob.signer,
109+
signer: blob.signer.hash,
110110
size: blob.size,
111111
tx: blob.tx,
112112
rollup: blob.rollup,
@@ -212,13 +212,13 @@ const handlePrev = () => {
212212
<td>
213213
<Tooltip position="start" delay="500">
214214
<Flex align="center" gap="8">
215-
<AddressBadge :hash="blob.signer" />
215+
<AddressBadge :account="blob.signer" />
216216
217-
<CopyButton :text="blob.signer" />
217+
<CopyButton :text="blob.signer.hash" />
218218
</Flex>
219219
220220
<template #content>
221-
{{ blob.signer }}
221+
{{ blob.signer.hash }}
222222
</template>
223223
</Tooltip>
224224
</td>

components/modules/namespace/tables/BlobsTable.vue

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -83,15 +83,15 @@ const handleViewBlob = (blob) => {
8383
</Tooltip>
8484
</td>
8585
<td v-else>
86-
<Tooltip v-if="blob.signer" position="start" delay="500">
86+
<Tooltip v-if="blob.signer.hash" position="start" delay="500">
8787
<Flex align="center" gap="8">
88-
<AddressBadge :hash="blob.signer" />
88+
<AddressBadge :account="blob.signer" />
8989

90-
<CopyButton :text="blob.signer" />
90+
<CopyButton :text="blob.signer.hash" />
9191
</Flex>
9292

9393
<template #content>
94-
{{ blob.signer }}
94+
{{ blob.signer.hash }}
9595
</template>
9696
</Tooltip>
9797
<Flex v-else align="center">

components/modules/rollup/tables/BlobsTable.vue

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -53,15 +53,15 @@ const handleViewBlob = (blob) => {
5353
<tbody>
5454
<tr v-for="blob in blobs" @click.stop="handleViewBlob(blob)">
5555
<td>
56-
<Tooltip v-if="blob.signer" position="start" delay="500">
56+
<Tooltip v-if="blob.signer.hash" position="start" delay="500">
5757
<Flex align="center" gap="8">
58-
<AddressBadge :hash="blob.signer" />
58+
<AddressBadge :account="blob.signer" />
5959

60-
<CopyButton :text="blob.signer" />
60+
<CopyButton :text="blob.signer.hash" />
6161
</Flex>
6262

6363
<template #content>
64-
{{ blob.signer }}
64+
{{ blob.signer.hash }}
6565
</template>
6666
</Tooltip>
6767
<Flex v-else align="center">

components/modules/stats/ChartCardPreview.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ const getSeries = async () => {
6666
days: props.period.timeframe === "day" ? props.period.value * 2 : 0,
6767
hours: props.period.timeframe === "hour" ? props.period.value * 2 : 0,
6868
}).ts / 1_000)
69-
})).reverse()
69+
})).map(v => { return { time: v.time, value: v.close } }).reverse()
7070
} else {
7171
data = (await fetchSeries({
7272
table: props.series.name,

components/modules/tx/TxOverview.vue

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -206,9 +206,9 @@ const handleViewRawTransaction = () => {
206206
<Flex align="center" justify="between">
207207
<Text size="12" weight="600" color="tertiary"> Signer</Text>
208208
<Flex align="center" gap="6">
209-
<AddressBadge :hash="tx.signers[0]" color="secondary" />
209+
<AddressBadge :account="tx.signers[0]" color="secondary" />
210210

211-
<CopyButton :text="tx.signers[0]" />
211+
<CopyButton :text="tx.signers[0].hash" />
212212
</Flex>
213213
</Flex>
214214
<Flex align="center" justify="between">

components/modules/validator/ValidatorOverview.vue

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,8 @@ const props = defineProps({
3131
},
3232
})
3333
34+
console.log('props.validator', props.validator);
35+
3436
const tabs = ref([
3537
{
3638
name: "Delegators",
@@ -277,9 +279,9 @@ const handleDelegate = () => {
277279
</Tooltip>
278280
</Flex>
279281
<Flex align="center" gap="6">
280-
<Text size="12" weight="600" color="tertiary"> {{ splitAddress(validator.address) }} </Text>
282+
<Text size="12" weight="600" color="tertiary"> {{ splitAddress(validator.address.hash) }} </Text>
281283
282-
<CopyButton :text="validator.address" />
284+
<CopyButton :text="validator.address.hash" />
283285
</Flex>
284286
</Flex>
285287
@@ -351,8 +353,8 @@ const handleDelegate = () => {
351353
<Flex align="center" justify="between">
352354
<Text size="12" weight="600" color="tertiary">Delegator Address</Text>
353355
<Flex gap="6">
354-
<AddressBadge :hash="validator.delegator" color="tertiary" />
355-
<CopyButton :text="validator.delegator" />
356+
<AddressBadge :account="validator.delegator" color="tertiary" />
357+
<CopyButton :text="validator.delegator.hash" />
356358
</Flex>
357359
</Flex>
358360

0 commit comments

Comments
 (0)