fix: add eth.link notification

This commit is contained in:
Danil Kovtonyuk 2022-08-02 20:20:56 +10:00 committed by GitHub
commit 498e1908e1
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 33 additions and 1 deletions

View File

@ -456,5 +456,10 @@
"trustBanner": {
"trustLess": "You are using a public IPFS gateway. Tornado Cash dApp can not use all security features of your browser. Check out {link} for alternatives",
"link": "landing page"
},
"ethLinkBanner": {
"notification": "Due to the {issue} with eth.link domain, we highly recommend avoiding using this gateway. Consider {alternative} gateways.",
"issue": "issue",
"alternative": "alternative"
}
}

View File

@ -49,6 +49,32 @@
</template>
</i18n>
</b-notification>
<b-notification
v-if="isEthLink"
:active="isActiveNotification.ethLink"
class="main-notification"
type="is-warning"
icon-pack="icon"
has-icon
:aria-close-label="$t('closeNotification')"
@close="disableNotification({ key: 'ethLink' })"
>
<i18n path="ethLinkBanner.notification">
<template v-slot:issue>
<a
href="https://discuss.ens.domains/t/eth-link-expiry/13899"
target="_blank"
rel="noopener noreferrer"
>{{ $t('ethLinkBanner.issue') }}</a
>
</template>
<template v-slot:alternative>
<a href="https://tornado.cash/">{{ $t('ethLinkBanner.alternative') }}</a>
</template>
</i18n>
</b-notification>
<div class="columns">
<div class="column is-half">
<b-tabs v-model="activeTab" class="is-tornado" :animated="false" @input="tabChanged">
@ -81,7 +107,8 @@ export default {
data() {
return {
activeTab: 0,
isActive: false
isActive: false,
isEthLink: window.location.host === 'tornadocash.eth.link'
}
},
computed: {