From 60d5984f9ade74ced096b6d5e470e22ba992d4ac Mon Sep 17 00:00:00 2001 From: Xavi Lee Date: Sun, 18 Feb 2024 12:43:27 +0800 Subject: [PATCH] docs(zh): tweak and sync translations (#3581) sync with https://github.com/vuejs/vitepress/commit/09030272b4a5c8f723b7e11303265f24b7481575 --- docs/zh/reference/default-theme-home-page.md | 34 +++++++++++++++++++- 1 file changed, 33 insertions(+), 1 deletion(-) diff --git a/docs/zh/reference/default-theme-home-page.md b/docs/zh/reference/default-theme-home-page.md index 87fb0377..e5d71482 100644 --- a/docs/zh/reference/default-theme-home-page.md +++ b/docs/zh/reference/default-theme-home-page.md @@ -136,11 +136,13 @@ interface Feature { // 点击 feature 组件时的链接,可以是内部链接,也可以是外部链接。 // + // // 例如 `guide/reference/default-theme-home-page` 或 `https://example.com` link?: string // feature 组件内显示的链接文本,最好与 `link` 选项一起使用 // + // // 例如 `Learn more`, `Visit page` 等 linkText?: string @@ -148,6 +150,9 @@ interface Feature { // // 例如 `external` rel?: string + + // `link` 选项的链接 target 属性 + target?: string } type FeatureIcon = @@ -160,4 +165,31 @@ type FeatureIcon = width?: string height: string } -``` \ No newline at end of file +``` + +## Markdown 内容 {#markdown-content} + +可以在 frontmatter 的分隔符 `---` 下方为站点主页添加额外的 Markdown 内容。 + +````md +--- +layout: home + +hero: + name: VitePress + text: Vite & Vue powered static site generator. +--- + +## Getting Started + +You can get started using VitePress right away using `npx`! + +```sh +npm init +npx vitepress init +``` +```` + +::: info +VitePress 并不总是为 `layout: home` 页面里额外的内容自动添加样式。要回到以前的行为,可以在 fortmatter 中添加 `markdownStyles: false`。 +:::