Files
mes-ui-d2/docs/.vuepress/config.js
liyang 2d6b4c9c4e 更新文档
Former-commit-id: 51e32071fb0681e01b7d44087373cef79f313bc8 [formerly 51e32071fb0681e01b7d44087373cef79f313bc8 [formerly 51e32071fb0681e01b7d44087373cef79f313bc8 [formerly 51e32071fb0681e01b7d44087373cef79f313bc8 [formerly 79ba796afad992898df5e973629c79fbbfac8c6d [formerly 5efb0f1da223916be314995822d7ac9d9324c775]]]]]
Former-commit-id: 4cd0293a16c4227f0aaa80f407a10efa18635968
Former-commit-id: b53f4fb6640a4ecb4d85bec0f422be29ddcfe8f0
Former-commit-id: 868ba63b2ab9f745c33ec97d47ece350916b3521 [formerly 7a8b9d1634902b4ba01266ba872b48fa2ca4aeea]
Former-commit-id: d5f9da35f948d90cf4d0673632412e6891143be3
Former-commit-id: 2f8850594b2e1dd452a8dd9d4b32a3a627d82920
Former-commit-id: 68bdb8cd8b0b6b0e19364afd3acde82d97fbad5e
Former-commit-id: 31e8787a6f6d9b0c3df05e0548303c0c2a2bb081
Former-commit-id: 5d7ae010aec91e0ada0bd65d72603dab8b536435
2018-07-06 20:00:54 +08:00

119 lines
2.7 KiB
JavaScript

module.exports = {
locales: {
'/': {
lang: 'en-US',
title: 'D2 Admin',
description: 'Elegant management system front-end integration'
},
'/zh/': {
lang: 'zh-CN',
title: 'D2 Admin',
description: '优雅的管理系统前端集成方案'
}
},
head: [
['link', { rel: 'icon', href: `/logo@2x.png` }],
['script', {}, 'var _hmt = _hmt || [];(function() {var hm = document.createElement("script");hm.src = "https://hm.baidu.com/hm.js?be9d34853430c136b5d62c3081d556a5";var s = document.getElementsByTagName("script")[0];s.parentNode.insertBefore(hm, s);})();']
],
themeConfig: {
// 项目仓库地址
repo: 'https://github.com/d2-projects/d2-admin',
// 自定义仓库链接文字
repoLabel: '查看源码',
// 文档不是放在仓库的根目录下
docsDir: 'docs',
// 默认是 false, 设置为 true 来启用
editLinks: true,
// 多国语言
locales: {
'/': {
selectText: 'Languages',
label: 'English',
editLinkText: 'Edit this page on GitHub',
lastUpdated: 'Last update',
nav: [
{ text: 'preview', link: 'https://fairyever.gitee.io/d2-admin-preview/#/index' }
]
},
'/zh/': {
selectText: '选择语言',
label: '简体中文',
editLinkText: '在 GitHub 上编辑此页',
lastUpdated: '最后更新',
nav: [
{ text: '指南', link: '/zh/guide/' },
{ text: '插件', link: '/zh/plugins/' },
{ text: '组件', link: '/zh/components/' },
{ text: '其它', link: '/zh/others/' },
{ text: '预览', link: 'https://fairyever.gitee.io/d2-admin-preview/#/index' }
],
sidebar: {
'/zh/guide/': sideBarGuide('指南'),
'/zh/plugins/': sideBarPlugins('插件'),
'/zh/components/': sideBarComponents('组件'),
'/zh/others/': sideBarOthers('其它')
}
}
}
}
}
function sideBarGuide (title) {
return [
{
title,
collapsable: false,
children: [
'',
'question',
'pr',
'change-log'
]
}
]
}
function sideBarPlugins () {
return [
'',
'data-export',
'data-import',
'i18n',
'mock'
]
}
function sideBarComponents (title) {
return [
{
title,
collapsable: false,
children: [
'',
'charts',
'charts-new',
'container',
'count-up',
'highlight',
'icon-select',
'icon-svg',
'icon',
'markdown'
]
}
]
}
function sideBarOthers (title) {
return [
{
title,
collapsable: false,
children: [
'',
'css'
]
}
]
}