Skip to content

Commit

Permalink
init
Browse files Browse the repository at this point in the history
  • Loading branch information
huanying liu committed Sep 15, 2024
1 parent 40f6eff commit 09cf89a
Show file tree
Hide file tree
Showing 34 changed files with 459 additions and 1,987 deletions.
6 changes: 1 addition & 5 deletions docs/.vuepress/config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,7 @@ export default defineUserConfig({
title: "Docs Demo",
description: "A docs demo for vuepress-theme-hope",
},
"/zh/": {
lang: "zh-CN",
title: "文档演示",
description: "vuepress-theme-hope 的文档演示",
},

},

theme,
Expand Down
30 changes: 4 additions & 26 deletions docs/.vuepress/navbar/en.ts
Original file line number Diff line number Diff line change
@@ -1,31 +1,9 @@
import { navbar } from "vuepress-theme-hope";

export const enNavbar = navbar([
"/",
"/portfolio",
"/demo/",
{
text: "Guide",
icon: "lightbulb",
prefix: "/guide/",
children: [
{
text: "Bar",
icon: "lightbulb",
prefix: "bar/",
children: ["baz", { text: "...", icon: "ellipsis", link: "#" }],
},
{
text: "Foo",
icon: "lightbulb",
prefix: "foo/",
children: ["ray", { text: "...", icon: "ellipsis", link: "#" }],
},
],
},
{
text: "V2 Docs",
icon: "book",
link: "https://theme-hope.vuejs.press/",
},
text: "Docs",
link: "/DOCS/README.md"
}

]);
19 changes: 3 additions & 16 deletions docs/.vuepress/sidebar/en.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,24 +3,11 @@ import { sidebar } from "vuepress-theme-hope";
export const enSidebar = sidebar({
"/": [
"",
"portfolio",
{
text: "Demo",
text: "DOCS",
icon: "laptop-code",
prefix: "demo/",
link: "demo/",
prefix: "DOCS/",
children: "structure",
},
{
text: "Docs",
icon: "book",
prefix: "guide/",
children: "structure",
},
{
text: "Slides",
icon: "person-chalkboard",
link: "https://plugin-md-enhance.vuejs.press/guide/content/revealjs/demo.html",
},
}
],
});
1 change: 0 additions & 1 deletion docs/.vuepress/sidebar/index.ts
Original file line number Diff line number Diff line change
@@ -1,2 +1 @@
export * from "./en.js";
export * from "./zh.js";
26 changes: 0 additions & 26 deletions docs/.vuepress/sidebar/zh.ts

This file was deleted.

31 changes: 8 additions & 23 deletions docs/.vuepress/theme.ts
Original file line number Diff line number Diff line change
@@ -1,21 +1,20 @@
import { hopeTheme } from "vuepress-theme-hope";

import { enNavbar, zhNavbar } from "./navbar/index.js";
import { enSidebar, zhSidebar } from "./sidebar/index.js";

export default hopeTheme({
hostname: "https://vuepress-theme-hope-docs-demo.netlify.app",
hostname: "https://blog.hying.fun",

author: {
name: "Mr.Hope",
url: "https://mister-hope.com",
name: "Hying",
url: "https://blog.hying.fun",
},

iconAssets: "fontawesome-with-brands",

logo: "https://theme-hope-assets.vuejs.press/logo.svg",

repo: "vuepress-theme-hope/vuepress-theme-hope",
repo: "https://github.com/lhy-a/lhy-a.github.io",

docsDir: "src",

Expand All @@ -36,25 +35,7 @@ export default hopeTheme({
},
},

/**
* Chinese locale config
*/
"/zh/": {
// navbar
navbar: zhNavbar,

// sidebar
sidebar: zhSidebar,

footer: "默认页脚",

displayFooter: true,

// page meta
metaLocales: {
editLink: "在 GitHub 上编辑此页",
},
},
},

encrypt: {
Expand All @@ -75,6 +56,10 @@ export default hopeTheme({
categoryId: "DIC_kwDOG_Pt2M4COD69",
},

searchPro: {
indexContent: true,
},

components: {
components: ["Badge", "VPCard"],
},
Expand Down
Loading

0 comments on commit 09cf89a

Please sign in to comment.