Skip to content

Commit

Permalink
fix: displays CCIP tooltip only once (#1425)
Browse files Browse the repository at this point in the history
  • Loading branch information
impelcrypto authored Dec 2, 2024
1 parent 14b3b96 commit 6f69b15
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/components/assets/EvmNativeToken.vue
Original file line number Diff line number Diff line change
Expand Up @@ -166,6 +166,7 @@ import { computed, defineComponent, ref, watch, watchEffect } from 'vue';
import { nativeBridgeEnabled, layerZeroBridgeEnabled, ccipMinatoBridgeEnabled } from 'src/features';
import CustomRouterLink from '../common/CustomRouterLink.vue';
import Balloon from 'src/components/common/Balloon.vue';
import { LOCAL_STORAGE } from 'src/config/localStorage';
export default defineComponent({
components: { ModalFaucet, CustomRouterLink, Balloon },
Expand Down Expand Up @@ -242,9 +243,11 @@ export default defineComponent({
watch(
[isShibuyaEvm],
async () => {
if (isShibuyaEvm.value) {
const isBallonDisplayed = Boolean(localStorage.getItem(LOCAL_STORAGE.BALLOON_CCIP_SHIBUYA));
if (isShibuyaEvm.value && !isBallonDisplayed) {
await wait(1000);
isCcipBalloon.value = true;
localStorage.setItem(LOCAL_STORAGE.BALLOON_CCIP_SHIBUYA, 'true');
}
},
{ immediate: true }
Expand Down
1 change: 1 addition & 0 deletions src/config/localStorage.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ export enum LOCAL_STORAGE {
XCM_TX_HISTORIES = 'xcmTxHistories',
XVM_TX_HISTORIES = 'xvmTxHistories',
BALLOON_NATIVE_TOKEN = 'balloonNativeToken',
BALLOON_CCIP_SHIBUYA = 'balloonCcipShibuya',
THEME_COLOR = 'themeColor',
MULTISIG = 'multisig',
CLOSE_DAPP_STAKING_V3_ONBOARDING = 'closeDappStakingV3Onboarding',
Expand Down

0 comments on commit 6f69b15

Please sign in to comment.