Skip to content

Commit

Permalink
Added more delay in adjusting transactions element height adjustment
Browse files Browse the repository at this point in the history
  • Loading branch information
joemarct committed Sep 8, 2022
1 parent 0fe7c4b commit 46d60fc
Showing 1 changed file with 9 additions and 4 deletions.
13 changes: 9 additions & 4 deletions src/pages/transaction/index.vue
Original file line number Diff line number Diff line change
Expand Up @@ -214,10 +214,7 @@ export default {
watch: {
startPageStatus (n, o) {
setTimeout(() => {
const sectionHeight = this.$refs.fixedSection.clientHeight
this.$refs.transactionSection.setAttribute('style', `position: relative; margin-top: ${sectionHeight - 24}px; z-index: 1`)
}, 100)
this.adjustTransactionsDivHeight()
},
selectedAsset () {
this.transactions = []
Expand Down Expand Up @@ -282,6 +279,12 @@ export default {
}
},
methods: {
adjustTransactionsDivHeight () {
setTimeout(() => {
const sectionHeight = this.$refs.fixedSection.clientHeight
this.$refs.transactionSection.setAttribute('style', `position: relative; margin-top: ${sectionHeight - 24}px; z-index: 1`)
}, 500)
},
formatDate (date) {
return ago(new Date(date))
},
Expand Down Expand Up @@ -772,6 +775,8 @@ export default {
vm.startPageStatus = false
}
vm.adjustTransactionsDivHeight()
if (Array.isArray(vm.assets) && this.assets.length > 0) {
vm.selectedAsset = this.bchAsset
}
Expand Down

0 comments on commit 46d60fc

Please sign in to comment.