diff --git a/src/common/rss3.ts b/src/common/rss3.ts index 0321c6d..27153d5 100644 --- a/src/common/rss3.ts +++ b/src/common/rss3.ts @@ -16,6 +16,7 @@ export type IRSS3 = RSS3; export interface IAssetProfile { assets: GeneralAsset[]; + status?: boolean; } export interface Theme { diff --git a/src/views/Home.vue b/src/views/Home.vue index 8f1aed9..d2b69e9 100644 --- a/src/views/Home.vue +++ b/src/views/Home.vue @@ -309,6 +309,28 @@ + + + + + +
this.rss3).accounts.get(this.ethAddress)); - const data = await RSS3.getAssetProfile(this.ethAddress); - - if (data) { - await this.loadAssets( - await (this.rss3).assets.get(this.ethAddress), - data.assets, - ); - this.isLoadingAssets = false; - } + const iv = setInterval(async () => { + const data = await RSS3.getAssetProfile((this.rss3).account.address, true); + if (data && data.status !== false) { + await this.loadAssets( + await (this.rss3).assets.get(this.ethAddress), + data.assets, + ); + this.isLoadingAssets = false; + clearInterval(iv); + } + }, 300); }, 0); setTimeout(async () => { @@ -686,10 +712,21 @@ export default class Home extends Vue { this.$router.push('/setup/accounts'); } toManageNFTs() { - this.$router.push('/setup/nfts'); + // this.saveEdited(); + if (this.isLoadingAssets) { + this.notice = 'NFTs still loading... Maybe check back later?'; + this.isShowingNotice = true; + } else { + this.$router.push('/setup/nfts'); + } } toManageGitcoins() { - this.$router.push('/setup/gitcoins'); + if (this.isLoadingAssets) { + this.notice = 'Gitcoins still loading... Maybe check back later?'; + this.isShowingNotice = true; + } else { + this.$router.push('/setup/gitcoins'); + } } public toAccountsPage() { diff --git a/src/views/Setup/RNSPending.vue b/src/views/Setup/RNSPending.vue index a5d93bd..ddaeed2 100644 --- a/src/views/Setup/RNSPending.vue +++ b/src/views/Setup/RNSPending.vue @@ -2,8 +2,8 @@
-
-

Preparing your RNS ...

+
+

Preparing your Pass ...

Hold on a little bit or come back later!

diff --git a/src/views/Setup/Setup.vue b/src/views/Setup/Setup.vue index d79f307..42af75a 100644 --- a/src/views/Setup/Setup.vue +++ b/src/views/Setup/Setup.vue @@ -44,7 +44,13 @@ class="mb-4 w-full" :is-having-content="nfts.length !== 0" :is-single-line="nfts.length !== 0" - :tips="isLoadingAssets ? 'Loading...' : nfts.length === 0 ? 'Haven\'t found anything yet...' : ''" + :tips=" + isLoadingAssets + ? 'Loading... Hold on a little bit or manage them later 🙌' + : nfts.length === 0 + ? 'Haven\'t found anything yet...' + : '' + " >