Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
Signed-off-by: MarcoMandar <[email protected]>
  • Loading branch information
MarcoMandar committed Aug 31, 2024
1 parent 3985448 commit 68a6a39
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 18 deletions.
27 changes: 9 additions & 18 deletions components/DataTableMyRelays/DataTableMyRelaysMobile.vue
Original file line number Diff line number Diff line change
Expand Up @@ -457,16 +457,17 @@ const handleUnlockClick = async (fingerprint: string) => {
<div class="font-semibold">Relay Fingerprint</div>
<FingerprintDisplay :fingerprint="row.fingerprint" />
</div>
<div class="flex justify-between items-center mt-2">
<div class="font-semibold">Consensus Weight</div>
<div class="font-semibold">Observed Bandwidth</div>
<div>
<span
v-if="
userStore?.relaysMeta?.[row.fingerprint]?.consensus_weight !==
userStore?.relaysMeta?.[row.fingerprint]?.observed_bandwidth !==
undefined
"
>
{{ userStore?.relaysMeta?.[row.fingerprint]?.consensus_weight }}
{{ getObservedBandwidth(row.fingerprint) }}
</span>
<span v-else class="text-sm flex items-center gap-2">
<Icon
Expand All @@ -478,22 +479,12 @@ const handleUnlockClick = async (fingerprint: string) => {
</div>
</div>
<div class="flex justify-between items-center mt-2">
<div class="font-semibold">Observed Bandwidth</div>
<div class="font-semibold">Previous Distribution</div>
<div>
<span
v-if="
userStore?.relaysMeta?.[row.fingerprint]?.observed_bandwidth !==
undefined
"
>
{{ getObservedBandwidth(row.fingerprint) }}
</span>
<span v-else class="text-sm flex items-center gap-2">
<Icon
name="heroicons:exclamation-circle"
class="h-4 w-4 text-red-500"
/>
Unable to fetch
<span>
{{
facilitatorStore?.distributionPerRelay?.[row.fingerprint] || '-'
}}
</span>
</div>
</div>
Expand Down
5 changes: 5 additions & 0 deletions constants/relay.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,15 @@ const defaultColumns: {
key: 'observedBandwidth',
label: 'Observed Bandwith',
},
// {
// key: 'consensusWeight',
// label: 'Consensus Weight',
// },
{
key: 'previousDistribution',
label: 'Previous Distribution',
},

{
key: 'lockStatus',
label: 'Lock Status',
Expand Down

0 comments on commit 68a6a39

Please sign in to comment.