Skip to content

Commit

Permalink
Merge branch 'main' of github.com:kodadot/nft-gallery into refactor/p…
Browse files Browse the repository at this point in the history
…rogrammatic-modal
  • Loading branch information
preschian committed Aug 15, 2023
2 parents c1137b7 + 614a3b0 commit 32c3ad9
Showing 1 changed file with 16 additions and 13 deletions.
29 changes: 16 additions & 13 deletions components/shared/Error.vue
Original file line number Diff line number Diff line change
Expand Up @@ -14,18 +14,21 @@
</p>
</div>
</template>
<script lang="ts">
import { Component, Prop, Vue } from 'nuxt-property-decorator'
@Component({})
export default class Error extends Vue {
@Prop({ default: 500 }) readonly errorCode!: number
@Prop({ default: true }) readonly hasImg!: boolean
@Prop({ default: 'Indexer Error' }) errorTitle!: string
@Prop({ default: 'Indexer is not working properly.' }) errorSubtitle!: string
get imgSrc() {
return `https://http.cat/${this.$props.errorCode}`
<script setup lang="ts">
const props = withDefaults(
defineProps<{
errorCode: number
hasImg: boolean
errorTitle: string
errorSubtitle: string
}>(),
{
errorCode: 500,
hasImg: true,
errorTitle: 'Indexer Error',
errorSubtitle: 'Indexer is not working properly.',
}
}
)
const imgSrc = computed(() => `https://http.cat/${props.errorCode}`)
</script>

0 comments on commit 32c3ad9

Please sign in to comment.