增加一些nft的熟悉
This commit is contained in:
parent
712e67d823
commit
4010be2768
BIN
src/assets/main/card/card_border_s.png
Normal file
BIN
src/assets/main/card/card_border_s.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 114 KiB |
@ -25,6 +25,12 @@
|
||||
<div class="active-bottom" v-if="currentTab==='market'"></div>
|
||||
</div>
|
||||
</a>
|
||||
<a class="menu-item" href="/mynft" v-if="logined" >
|
||||
<div class="item " :class="{'active': currentTab==='mynft'}">
|
||||
MyNFT
|
||||
<div class="active-bottom" v-if="currentTab==='mynft'"></div>
|
||||
</div>
|
||||
</a>
|
||||
</div>
|
||||
|
||||
<div class="rightContainer">
|
||||
@ -65,6 +71,7 @@
|
||||
<a class="navItem" href="/">Home</a>
|
||||
<a class="navItem" href="/official" >Official Shop</a>
|
||||
<a class="navItem dash" href="/market">Marketplace</a>
|
||||
<a class="navItem" href="/mynft" v-if="logined">MyNFT</a>
|
||||
<label v-if="!logined" class="navItem" @click="collectToWallet">Connect Wallet</label>
|
||||
<button v-if="!logined" class="general-btn connectButton mobile" @click="collectToWallet">
|
||||
<span>Connect Wallet</span>
|
||||
|
@ -2,7 +2,7 @@
|
||||
<a class="card-outlet" :href="!nftData.hideAttr? `/item/${nftData.id}`: 'javascript:void(0)'">
|
||||
<div class="nft-id">#{{nftData.id}}</div>
|
||||
<div class="card" >
|
||||
<img v-if="nftData.id" class="bg-img" src="@/assets/main/card/card_border.png" alt="">
|
||||
<img v-if="nftData.id" class="bg-img" :src="cardBg" alt="">
|
||||
<div v-if="nftData.id" class="anim-border">
|
||||
<img class="card-main-img" :src="nftData.image" alt=""/>
|
||||
<div class="info-bar" :class="{'bottom': !nftData.showBuy}">
|
||||
@ -29,7 +29,7 @@ import { Component, Prop, Vue } from 'vue-property-decorator'
|
||||
import { AppModule } from '@/store/modules/app'
|
||||
import { UserModule } from '@/store/modules/user'
|
||||
import ChainManager from '@/chain/ChainManager'
|
||||
import { defaultINftData, INftData } from '@/types/Nft'
|
||||
import { INftData } from '@/types/Nft'
|
||||
|
||||
@Component({
|
||||
name: 'HeroNft',
|
||||
@ -44,6 +44,14 @@ export default class HeroNft extends Vue {
|
||||
return AppModule.walletConnected
|
||||
}
|
||||
|
||||
get cardBg() {
|
||||
if (this.nftData.isGenesis) {
|
||||
return require('@/assets/main/card/card_border_s.png')
|
||||
} else {
|
||||
return require('@/assets/main/card/card_border.png')
|
||||
}
|
||||
}
|
||||
|
||||
// get showLight() {
|
||||
// return !this.accountId || this.canBuy
|
||||
// }
|
||||
|
@ -43,6 +43,7 @@ export interface INftData{
|
||||
extAttrList: KeyValuePair[]
|
||||
showBuy?: boolean
|
||||
hideAttr?: boolean
|
||||
isGenesis?: boolean
|
||||
}
|
||||
export const defaultINftData = () => {
|
||||
return {
|
||||
@ -89,6 +90,7 @@ export function parseNftData(data: any) {
|
||||
mintTime: data.mint_time,
|
||||
job: info.job,
|
||||
hideAttr: data.hide_attr,
|
||||
isGenesis: data.is_genesis,
|
||||
attrMap,
|
||||
extAttrList
|
||||
}
|
||||
|
@ -60,7 +60,7 @@ import { INftData, parseNftData } from '@/types/Nft'
|
||||
})
|
||||
export default class MyNft extends Vue {
|
||||
mobileFilterShow = false
|
||||
currentTab = ''
|
||||
currentTab = 'mynft'
|
||||
nftList: INftData[] = []
|
||||
nftType = 1
|
||||
nftState = 0
|
||||
|
Loading…
x
Reference in New Issue
Block a user