diff --git a/docs/guide/frontmatter.md b/docs/guide/frontmatter.md index 5fc176c4..bc7ad57e 100644 --- a/docs/guide/frontmatter.md +++ b/docs/guide/frontmatter.md @@ -19,7 +19,7 @@ title: Docs with VitePress editLink: true --- -# {{ $page.frontmatter.title }} +# {{ $frontmatter.title }} Guide content ``` diff --git a/docs/guide/global-computed.md b/docs/guide/global-computed.md index f7de2fb2..4d2eac0d 100644 --- a/docs/guide/global-computed.md +++ b/docs/guide/global-computed.md @@ -14,7 +14,7 @@ This is the `$site` value of the site you’re currently reading: "locales": {}, "base": "/", "head": [], - "themeConfig: $theme + "themeConfig: $themeConfig } ``` @@ -55,7 +55,7 @@ Reference of [\$page](#page).frontmatter. } ``` -## \$theme +## \$themeConfig Refers to `$site.themeConfig`. diff --git a/src/client/app/index.ts b/src/client/app/index.ts index 7749278d..847e5e70 100644 --- a/src/client/app/index.ts +++ b/src/client/app/index.ts @@ -92,7 +92,7 @@ export function createApp() { return router.route.data.frontmatter } }, - $theme: { + $themeConfig: { get() { return siteDataByRouteRef.value.themeConfig } diff --git a/src/client/theme-default/components/NavBarTitle.vue b/src/client/theme-default/components/NavBarTitle.vue index bafdc6c7..58338fda 100644 --- a/src/client/theme-default/components/NavBarTitle.vue +++ b/src/client/theme-default/components/NavBarTitle.vue @@ -5,9 +5,9 @@ :aria-label="`${$site.title}, back to home`" > {{ $site.title }} @@ -37,7 +37,7 @@ export default defineComponent({ } .logo { - margin-right: .75rem; + margin-right: 0.75rem; height: 1.3rem; vertical-align: bottom; }