4
4
<div class =" tile is-6 is-vertical is-parent" >
5
5
<div class =" tile is-child box" >
6
6
<b-image
7
- v-if =" imageVisible"
7
+ v-if =" !isLoading && imageVisible"
8
8
:src =" nft.image || require('@/assets/kodadot_logo_v1_transparent_400px.png')"
9
9
:src-fallback =" require('@/assets/kodadot_logo_v1_transparent_400px.png')"
10
10
alt =" NFT minted image"
11
11
ratio =" 1by1"
12
12
></b-image >
13
+ <b-skeleton height =" 524px" size =" is-large" :active =" isLoading" ></b-skeleton >
13
14
<MediaResolver v-if =" nft.animation_url" :class =" { withPicture: imageVisible }" :src =" nft.animation_url" :mimeType =" mimeType" />
14
15
<Appreciation :accountId =" accountId" :currentOwnerId =" nft.currentOwner" :nftId =" nft.id" />
15
16
<div class =" card" >
18
19
{{ $t('legend')}}
19
20
</p >
20
21
<p class =" subtitle is-size-7" >
21
- <b ># {{ nftId }}</b >
22
+ <b v-if =" !isLoading" ># {{ nftId }}</b >
23
+ <b-skeleton size =" is-large" :active =" isLoading" ></b-skeleton >
22
24
<b-tag v-if =" nft.price" type =" is-dark" size =" is-medium" >
23
25
<Money :value =" nft.price" :inline =" true" />
24
26
</b-tag >
25
- <p class =" subtitle is-size-5" >
27
+ <p v-if =" !isLoading"
28
+ class =" subtitle is-size-5" >
26
29
{{ nft.description }}
27
30
</p >
31
+ <b-skeleton count =" 3" size =" is-large" :active =" isLoading" ></b-skeleton >
28
32
</p >
29
33
</div >
30
34
</div >
40
44
role =" button"
41
45
aria-controls =" contentIdForA11y3" >
42
46
<p class =" card-header-title is-size-1" >
43
- {{ nft.name }}
47
+ <span v-if =" !isLoading" >
48
+ {{ nft.name }}
49
+ </span >
50
+ <b-skeleton height =" 100px" size =" is-large" :active =" isLoading" ></b-skeleton >
44
51
</p >
45
52
<a class =" card-header-icon" >
46
53
<b-icon
@@ -241,7 +248,7 @@ export default class GalleryItem extends Vue {
241
248
private passsword: string = ' ' ;
242
249
private nft: NFTType = emptyObject <NFTType >();
243
250
private imageVisible: boolean = true ;
244
- private isLoading: boolean = false ;
251
+ public isLoading: boolean = true ;
245
252
246
253
@Prop () public value! : any ;
247
254
@@ -255,8 +262,6 @@ export default class GalleryItem extends Vue {
255
262
return ;
256
263
}
257
264
258
- this .isLoading = true ;
259
-
260
265
try {
261
266
const nft = await rmrkService .getNFT (this .id );
262
267
console .log (nft );
0 commit comments