更新任务
This commit is contained in:
1 parent
120a57ad57
commit
6118a80ac4
279 files changed
+9682
-2362
No files matched your search
@@ -0,0 +1,11 @@
|
||||
import { defineConfig } from 'vitepress'
|
||||
|
||||
import shared from './shared'
|
||||
import zh from './zh'
|
||||
|
||||
export default defineConfig({
|
||||
...shared,
|
||||
locales: {
|
||||
root: { label: '简体中文', ...zh },
|
||||
}
|
||||
})
|
||||
@@ -0,0 +1,85 @@
|
||||
import { defineConfig, type SiteConfig } from 'vitepress'
|
||||
// 自动导入 TDesign
|
||||
import AutoImport from 'unplugin-auto-import/vite'
|
||||
import Components from 'unplugin-vue-components/vite'
|
||||
import { TDesignResolver } from 'unplugin-vue-components/resolvers'
|
||||
|
||||
import { handleHeadMeta } from '../theme/utils/handleHeadMeta'
|
||||
import { search as zhSearch } from './zh'
|
||||
|
||||
// https://vitepress.dev/reference/site-config
|
||||
export default defineConfig({
|
||||
lastUpdated: true,
|
||||
cleanUrls: true,
|
||||
ignoreDeadLinks: true,
|
||||
sitemap: {
|
||||
hostname: 'https://duyl328.github.io',
|
||||
},
|
||||
base: 'https://duyl328.github.io',
|
||||
head: [
|
||||
// 谷歌分析,暂不使用
|
||||
// ['script',
|
||||
// {
|
||||
// async: '',
|
||||
// src: 'https://www.googletagmanager.com/gtag/js?id=G-MB7XVBG1TQ',
|
||||
// }],
|
||||
// [
|
||||
// 'script',
|
||||
// {},
|
||||
// `window.dataLayer = window.dataLayer || [];
|
||||
// function gtag(){dataLayer.push(arguments);}
|
||||
// gtag('js', new Date());
|
||||
// gtag('config', 'G-MB7XVBG1TQ');`,
|
||||
// ],
|
||||
|
||||
[
|
||||
'link',
|
||||
{
|
||||
rel: 'icon',
|
||||
// href: '',
|
||||
},
|
||||
],
|
||||
],
|
||||
// https://vitepress.dev/reference/site-config#transformhead
|
||||
async transformHead (context) {
|
||||
return handleHeadMeta(context)
|
||||
},
|
||||
buildEnd: (config: SiteConfig) => {
|
||||
},
|
||||
|
||||
themeConfig: {
|
||||
// https://vitepress.dev/reference/default-theme-config
|
||||
outline: [2, 4],
|
||||
|
||||
search: {
|
||||
provider: 'local',
|
||||
options: {
|
||||
locales: { ...zhSearch },
|
||||
},
|
||||
},
|
||||
|
||||
externalLinkIcon: true,
|
||||
},
|
||||
|
||||
markdown: {
|
||||
math: true,
|
||||
},
|
||||
|
||||
vite: {
|
||||
plugins: [
|
||||
// ...
|
||||
AutoImport({
|
||||
resolvers: [
|
||||
TDesignResolver({
|
||||
library: 'vue-next',
|
||||
})],
|
||||
}),
|
||||
Components({
|
||||
resolvers: [
|
||||
TDesignResolver({
|
||||
library: 'vue-next',
|
||||
})],
|
||||
}),
|
||||
],
|
||||
},
|
||||
})
|
||||
@@ -0,0 +1,89 @@
|
||||
import { type DefaultTheme, defineConfig } from 'vitepress'
|
||||
|
||||
import { createSideBarZH } from '../theme/utils/createSideBar'
|
||||
|
||||
// https://vitepress.dev/reference/site-config
|
||||
export default defineConfig({
|
||||
title: 'duyl328',
|
||||
description: '广泛涉猎的开发者, 主要使用:kotlin、vue, 还会点 Python、c#、java、rust',
|
||||
lang: 'zh-Hans', //语言
|
||||
themeConfig: {
|
||||
// https://vitepress.dev/reference/default-theme-config
|
||||
nav: [
|
||||
{ text: '博客', link: '/' },
|
||||
{ text: '归档', link: '/archive', activeMatch: '/archive' },
|
||||
{ text: '笔记', link: '/notes/', activeMatch: '/notes/' },
|
||||
{ text: '关于', link: '/about', activeMatch: '/about' },
|
||||
// { text: "赞助", link: "/support-me", activeMatch: '/support-me' },
|
||||
],
|
||||
docFooter: {
|
||||
prev: '上一篇',
|
||||
next: '下一篇',
|
||||
},
|
||||
|
||||
outline: {
|
||||
label: '当前页面',
|
||||
},
|
||||
lastUpdated: {
|
||||
text: '最近更新时间',
|
||||
},
|
||||
|
||||
sidebar: createSideBarZH(),
|
||||
|
||||
socialLinks: [
|
||||
{ icon: 'github', link: 'https://github.com/duyl328' },
|
||||
],
|
||||
|
||||
editLink: {
|
||||
pattern: 'https://duyl328.github.io/edit/master/docs/:path',
|
||||
text: '在 GitHub 上编辑此页',
|
||||
},
|
||||
returnToTopLabel: '回到顶部',
|
||||
sidebarMenuLabel: '目录',
|
||||
darkModeSwitchLabel: '深色模式',
|
||||
},
|
||||
})
|
||||
|
||||
export const search: DefaultTheme.AlgoliaSearchOptions['locales'] = {
|
||||
root: {
|
||||
placeholder: '搜索文档',
|
||||
translations: {
|
||||
button: {
|
||||
buttonText: '搜索文档',
|
||||
buttonAriaLabel: '搜索文档',
|
||||
},
|
||||
modal: {
|
||||
searchBox: {
|
||||
resetButtonTitle: '清除查询条件',
|
||||
resetButtonAriaLabel: '清除查询条件',
|
||||
cancelButtonText: '取消',
|
||||
cancelButtonAriaLabel: '取消',
|
||||
},
|
||||
startScreen: {
|
||||
recentSearchesTitle: '搜索历史',
|
||||
noRecentSearchesText: '没有搜索历史',
|
||||
saveRecentSearchButtonTitle: '保存至搜索历史',
|
||||
removeRecentSearchButtonTitle: '从搜索历史中移除',
|
||||
favoriteSearchesTitle: '收藏',
|
||||
removeFavoriteSearchButtonTitle: '从收藏中移除',
|
||||
},
|
||||
errorScreen: {
|
||||
titleText: '无法获取结果',
|
||||
helpText: '你可能需要检查你的网络连接',
|
||||
},
|
||||
footer: {
|
||||
selectText: '选择',
|
||||
navigateText: '切换',
|
||||
closeText: '关闭',
|
||||
searchByText: '搜索提供者',
|
||||
},
|
||||
noResultsScreen: {
|
||||
noResultsText: '无法找到相关结果',
|
||||
suggestedQueryText: '你可以尝试查询',
|
||||
reportMissingResultsText: '你认为该查询应该有结果?',
|
||||
reportMissingResultsLinkText: '点击反馈',
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
}
|
||||
Reference in new issue
Block a user