Skip to content

Commit

Permalink
add governance link to mobile nav
Browse files Browse the repository at this point in the history
  • Loading branch information
gtg7784 committed Oct 28, 2024
1 parent 5bddcf0 commit 011fe52
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions src/components/header/mobile/MobileNav.vue
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,9 @@
<span class="text--link">{{ $t('sidenavi.forum') }}</span>
</div>
</a>
<a href="" target="_blank">{{ $t('sidenavi.governance') }}</a>
<a v-if="isGovernanceEnabled" :href="governanceUrl" target="_blank">{{
$t('sidenavi.governance')
}}</a>
</nav>
<a class="lfgm-mobile" :href="lfgmUrl" target="_blank">
<img :src="require('src/assets/img/lfgm.svg')" alt="LFGM" />
Expand Down Expand Up @@ -93,7 +95,7 @@
<script lang="ts">
import { defineComponent, ref, computed } from 'vue';
import { useRouter } from 'vue-router';
import { useBreakpoints, useNetworkInfo } from 'src/hooks';
import { useBreakpoints, useNetworkInfo, useGovernance } from 'src/hooks';
import { Path as RoutePath } from 'src/router/routes';
import { lfgmUrl, socialUrl } from 'src/links';
import { useStore } from 'src/store';
Expand All @@ -112,6 +114,7 @@ export default defineComponent({
const router = useRouter();
const path = computed(() => router.currentRoute.value.path.split('/')[2]);
const { isZkyoto } = useNetworkInfo();
const { isGovernanceEnabled, governanceUrl } = useGovernance();
const store = useStore();
const currentNetworkIdx = computed(() => store.getters['general/networkIdx']);
Expand All @@ -127,6 +130,8 @@ export default defineComponent({
isZkyoto,
lfgmUrl,
socialUrl,
isGovernanceEnabled,
governanceUrl,
};
},
});
Expand Down

0 comments on commit 011fe52

Please sign in to comment.