Skip to content

Commit

Permalink
Add smart rollup type to info
Browse files Browse the repository at this point in the history
  • Loading branch information
GusevPM committed Aug 21, 2023
1 parent 4307ec8 commit 48498a9
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 2 deletions.
13 changes: 13 additions & 0 deletions src/views/contract/InfoSection/SmartRollupInfo.vue
Original file line number Diff line number Diff line change
Expand Up @@ -131,13 +131,25 @@
</v-card-text>
</v-card>
</v-dialog>
<v-list-item>
<v-list-item-content>
<v-list-item-subtitle class="overline"
>Type</v-list-item-subtitle
>
<v-list-item-title class="body-2">
<TypeDef :typedef="smartRollup.type" class="body-2"/>
</v-list-item-title>
</v-list-item-content>
</v-list-item>
</v-skeleton-loader>
</v-list>
</template>

<script>
import ValueInspector from "@/components/ValueInspector.vue"
import TypeDef from "@/views/contract/TypeDef.vue";
export default {
name: "SmartRollupInfo",
Expand All @@ -148,6 +160,7 @@ export default {
},
components: {
ValueInspector,
TypeDef,
},
data: () => ({
infoLoading: true,
Expand Down
5 changes: 3 additions & 2 deletions src/views/contract/TypeDef.vue
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
<template>
<div class="d-flex flex-column parameters">
<div v-for="(def, i) in typedef" :key="i" class="mb-2">
<span v-if="i === 0" class="font-weight-light">{{ first }}&nbsp;</span>
<div v-for="(def, i) in typedef" :key="i" class="mb-0">
<span v-if="i === 0 && (!first)" class="font-weight-light"></span>
<span v-else-if="i === 0" class="font-weight-light">{{ first }}&nbsp;</span>
<span v-else-if="def.name" class="font-weight-light">{{ def.name }}&nbsp;</span>
<span class="tree--text" v-html="highlightType(def.type)"></span>
<div v-for="(arg, j) in def.args" :key="i + j" class="pl-4">
Expand Down

0 comments on commit 48498a9

Please sign in to comment.