Skip to content

Commit abc119e

Browse files
authored
Merge pull request #392 from vuejs-jp/fix/add-baseurl
fix: add basePath on return-top-link
2 parents 24f1f90 + 3b4c888 commit abc119e

File tree

3 files changed

+9
-6
lines changed

3 files changed

+9
-6
lines changed

Diff for: apps/web/app/error.vue

+3-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<script setup lang="ts">
2-
import { useHead } from '#imports'
2+
import { useHead, useWithBase } from '#imports'
33
import { useColor, useTypography } from '@vuejs-jp/composable'
44
import { conferenceTitle } from '~/utils/constants'
55
import { generalOg, twitterOg } from '~/utils/og.constants'
@@ -13,6 +13,7 @@ const props = defineProps<ErrorProps>()
1313
1414
const { fontWeight, fontSize } = useTypography()
1515
const { color } = useColor()
16+
const withBase = useWithBase()
1617
1718
useHead({
1819
// eslint-disable-next-line no-unused-vars
@@ -49,7 +50,7 @@ useHead({
4950
background-color="white"
5051
color="vue-blue"
5152
target=""
52-
href="/"
53+
:href="withBase('/')"
5354
>
5455
{{ $t('back_to_top') }}
5556
</VFLinkButton>

Diff for: apps/web/app/pages/code-of-conduct.vue

+3-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<script setup lang="ts">
2-
import { useHead } from '#imports'
2+
import { useHead, useWithBase } from '#imports'
33
import { useColor, useTypography } from '@vuejs-jp/composable'
44
import { useLocaleCurrent } from '~/composables/useLocaleCurrent'
55
import { conferenceTitle, linkUrl, ogCoCDescription } from '~/utils/constants'
@@ -27,6 +27,7 @@ useHead({
2727
const { path: localePath } = useLocaleCurrent()
2828
const { fontWeight, fontSize } = useTypography()
2929
const { color } = useColor()
30+
const withBase = useWithBase()
3031
</script>
3132

3233
<template>
@@ -58,7 +59,7 @@ const { color } = useColor()
5859
background-color="white"
5960
color="vue-blue"
6061
target=""
61-
:href="`${localePath}/`"
62+
:href="withBase(`${localePath}/`)"
6263
>
6364
{{ $t('back_to_top') }}
6465
</VFLinkButton>

Diff for: apps/web/app/pages/tokusho.vue

+3-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<script setup lang="ts">
2-
import { useHead } from '#imports'
2+
import { useHead, useWithBase } from '#imports'
33
import { useColor, useTypography } from '@vuejs-jp/composable'
44
import { useLocaleCurrent } from '~/composables/useLocaleCurrent'
55
import { conferenceTitle, linkUrl, ogTokushoDescription } from '~/utils/constants'
@@ -27,6 +27,7 @@ useHead({
2727
const { path: localePath } = useLocaleCurrent()
2828
const { fontWeight, fontSize } = useTypography()
2929
const { color } = useColor()
30+
const withBase = useWithBase()
3031
</script>
3132

3233
<template>
@@ -58,7 +59,7 @@ const { color } = useColor()
5859
background-color="white"
5960
color="vue-blue"
6061
target=""
61-
:href="`${localePath}/`"
62+
:href="withBase(`${localePath}/`)"
6263
>
6364
{{ $t('back_to_top') }}
6465
</VFLinkButton>

0 commit comments

Comments
 (0)