Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
vivien8261 committed Jul 2, 2024
1 parent 4a80a5b commit be18e89
Show file tree
Hide file tree
Showing 2 changed files with 41 additions and 27 deletions.
46 changes: 30 additions & 16 deletions docs/.vitepress/nav/navbar.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,13 @@
import { adapters } from './sidebar'
import sidebar, { adapters } from './sidebar'

function getFirstNav(navItems) {
return navItems.map(item => {
return {
text: item.text,
link: item.items[0].link
}
})
}

export default [
{
Expand All @@ -15,8 +24,8 @@ export default [
{
text: '开发指南',
items: [
{ text: '基础指南', link: '/develop/basic/index.md' },
{ text: '进阶指南', link: '/develop/advanced/' },
{ text: '基础', items: getFirstNav(sidebar['/develop/basic/']) },
{ text: '进阶', items: getFirstNav(sidebar['/develop/advanced/']) },
{ text: '插件开发', link: '/develop/plugin/' },
]
},
Expand All @@ -25,7 +34,7 @@ export default [
items: adapters
},
{
text: '兔兔-V6',
text: '兔兔机器人',
items: [
{
text: '部署',
Expand All @@ -41,19 +50,24 @@ export default [
]
},
{
text: '下载',
link: '/download'
},
{
text: '赞助',
link: '/sponsor'
text: '联系我们',
items: [
{
text: '赞助',
link: '/sponsor'
},
{
text: '官方群',
link: 'https://qm.qq.com/q/9ft0w6HQj0'
},
{
text: '官方频道',
link: 'https://qun.qq.com/qqweb/qunpro/share?_wv=3&_wwv=128&appChannel=share&inviteCode=1W4sJux&appChannel=share&businessType=9&from=181074&biz=ka&shareSource=5'
}
]
},
{
text: '官方群',
link: 'https://qm.qq.com/q/9ft0w6HQj0'
text: '下载',
link: '/download'
},
{
text: '官方频道',
link: 'https://qun.qq.com/qqweb/qunpro/share?_wv=3&_wwv=128&appChannel=share&inviteCode=1W4sJux&appChannel=share&businessType=9&from=181074&biz=ka&shareSource=5'
}
]
22 changes: 11 additions & 11 deletions docs/.vitepress/nav/sidebar.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,15 +14,15 @@ export const adapters = [
export default {
'/develop/basic/': [
{
text: '起步',
text: '创建实例',
collapsible: true,
items: [
{ text: '开始使用', link: '/develop/basic/index.md' },
{ text: '多账号', link: '/develop/basic/multipleAccounts.md' }
]
},
{
text: '基础开发',
text: '接收&发送消息',
collapsible: true,
items: [
{ text: '声明', link: '/develop/basic/statement.md' },
Expand All @@ -34,6 +34,14 @@ export default {
{ text: '撤回消息', link: '/develop/basic/recallMessage.md' }
]
},
{
text: '事件&异常',
collapsible: true,
items: [
{ text: '事件监听', link: '/develop/basic/handleEvents.md' },
{ text: '异常监听', link: '/develop/basic/handleException.md' }
]
},
{
text: '消息构建元素',
collapsible: true,
Expand Down Expand Up @@ -64,15 +72,7 @@ export default {
]
},
{
text: '监听',
collapsible: true,
items: [
{ text: '事件监听', link: '/develop/basic/handleEvents.md' },
{ text: '异常监听', link: '/develop/basic/handleException.md' }
]
},
{
text: '测试',
text: '调试',
collapsible: true,
items: [
{ text: '使用测试实例调试', link: '/develop/basic/testInstance.md' }
Expand Down

0 comments on commit be18e89

Please sign in to comment.