mirror of
https://github.com/tornadocash/tornado-initiation-ui.git
synced 2024-11-26 11:39:04 +01:00
0fe0b3bbc5
enable loading
44 lines
999 B
Vue
44 lines
999 B
Vue
<template>
|
|
<div class="notices is-top">
|
|
<b-notification
|
|
v-for="notice in notices"
|
|
:key="notice.id"
|
|
class="is-top-right"
|
|
has-icon
|
|
:icon="notice.type"
|
|
:aria-close-label="$t('closeNotification')"
|
|
role="alert"
|
|
@close="close(notice.id)"
|
|
>
|
|
<i18n :path="notice.title.path || notice.title" tag="span">
|
|
<template v-slot:value>
|
|
<b>{{ notice.title.value }}</b>
|
|
</template>
|
|
</i18n>
|
|
<a
|
|
v-if="notice.txHash"
|
|
:href="txExplorerUrl(notice.txHash)"
|
|
target="_blank"
|
|
>
|
|
{{ $t('viewOnEtherscan') }}
|
|
</a>
|
|
</b-notification>
|
|
</div>
|
|
</template>
|
|
|
|
<script>
|
|
import { mapState, mapGetters, mapActions } from 'vuex'
|
|
export default {
|
|
computed: {
|
|
...mapState('notice', ['notices']),
|
|
...mapGetters('txHashKeeper', ['txExplorerUrl']),
|
|
},
|
|
methods: {
|
|
...mapActions('notice', ['deleteNotice']),
|
|
close(id) {
|
|
this.deleteNotice({ id })
|
|
},
|
|
},
|
|
}
|
|
</script>
|