forked from LaconicNetwork/cosmos-explorer
feat: Parameters Application Version and Node Information
This commit is contained in:
@@ -21,8 +21,7 @@ const props = defineProps({
|
||||
class="rounded-sm bg-active px-4 py-2"
|
||||
>
|
||||
<div class="text-xs mb-2 text-secondary">{{ item?.subtitle }}</div>
|
||||
<div class="text-base text-main">{{ item?.value }}</div>
|
||||
<!-- {{ item }} -->
|
||||
<div class="text-base text-main">{{ Array.isArray(item?.value) ? (item?.value[0] && item?.value[0].amount)|| '-':`${Number(item?.value)}` === 'NaN' ? item?.value : Number(item?.value)}}</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -3,7 +3,7 @@ import { computed } from '@vue/reactivity';
|
||||
import DynamicComponent from './DynamicComponent.vue';
|
||||
|
||||
const props = defineProps({
|
||||
value: { type: Array<Object>},
|
||||
value: { type: null as any },
|
||||
thead: {
|
||||
type: Boolean,
|
||||
default: true
|
||||
@@ -22,13 +22,17 @@ const header = computed(() => {
|
||||
<VTable v-if="header.length > 0" density="compact" height="300px" fixed-header hover>
|
||||
<thead v-if="thead">
|
||||
<tr>
|
||||
<th v-for="k in header" class="text-left text-capitalize">{{ k }}</th>
|
||||
<th v-for="(item, index) in header" :key="index" class="text-left text-capitalize">{{ item }}</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr v-for="v in props.value">
|
||||
<td v-for="k in header"> <DynamicComponent :value="v[k]" /></td>
|
||||
<tr v-for="(item, index) in value" :key="index">
|
||||
<td v-for="(el, key) in header" :key="key"> <DynamicComponent :value="item[el]" /></td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</VTable>
|
||||
|
||||
<div v-else class="h-[300px]">
|
||||
|
||||
</div>
|
||||
</template>
|
||||
Reference in New Issue
Block a user