|
| 1 | +import { defineConfig } from 'vitepress' |
| 2 | + |
| 3 | +export default defineConfig({ |
| 4 | + base: '/', |
| 5 | + |
| 6 | + title: "Miuix", |
| 7 | + |
| 8 | + description: "A UI library for Compose MultiPlatform", |
| 9 | + |
| 10 | + head: [ |
| 11 | + ['link', { rel: 'icon', href: '/Icon.webp' }], |
| 12 | + ['link', { rel: 'preconnect', href: 'https://cdn-font.hyperos.mi.com/font/css?family=MiSans_VF:VF:Chinese_Simplify,Latin&display=swap' }], |
| 13 | + ], |
| 14 | + |
| 15 | + markdown: { |
| 16 | + image: { |
| 17 | + lazyLoading: true, |
| 18 | + }, |
| 19 | + }, |
| 20 | + |
| 21 | + lastUpdated: true, |
| 22 | + |
| 23 | + cleanUrls: true, |
| 24 | + |
| 25 | + lang: 'zh-Hans', |
| 26 | + |
| 27 | + themeConfig: { |
| 28 | + logo: '/Icon.webp', |
| 29 | + |
| 30 | + search: { |
| 31 | + provider: 'local', |
| 32 | + options: { |
| 33 | + translations: { |
| 34 | + button: { |
| 35 | + buttonText: '搜索文档', |
| 36 | + buttonAriaLabel: '搜索文档' |
| 37 | + }, |
| 38 | + modal: { |
| 39 | + noResultsText: '无法找到相关结果', |
| 40 | + resetButtonTitle: '清除查询条件', |
| 41 | + footer: { |
| 42 | + selectText: '选择', |
| 43 | + navigateText: '切换', |
| 44 | + closeText: '关闭', |
| 45 | + }, |
| 46 | + }, |
| 47 | + }, |
| 48 | + }, |
| 49 | + }, |
| 50 | + |
| 51 | + docFooter: { |
| 52 | + prev: '上一页', |
| 53 | + next: '下一页' |
| 54 | + }, |
| 55 | + |
| 56 | + outline: { |
| 57 | + label: '页面导航' |
| 58 | + }, |
| 59 | + |
| 60 | + lastUpdated: { |
| 61 | + text: '最后更新于', |
| 62 | + formatOptions: { |
| 63 | + dateStyle: 'short', |
| 64 | + timeStyle: 'medium' |
| 65 | + } |
| 66 | + }, |
| 67 | + |
| 68 | + langMenuLabel: '多语言', |
| 69 | + returnToTopLabel: '回到顶部', |
| 70 | + sidebarMenuLabel: '菜单', |
| 71 | + darkModeSwitchLabel: '主题', |
| 72 | + lightModeSwitchTitle: '切换到浅色模式', |
| 73 | + darkModeSwitchTitle: '切换到深色模式', |
| 74 | + skipToContentLabel: '跳转到内容', |
| 75 | + |
| 76 | + socialLinks: [ |
| 77 | + { icon: 'github', link: 'https://github.com/YuKongA/miuix-kotlin-multiplatform' } |
| 78 | + ], |
| 79 | + |
| 80 | + editLink: { |
| 81 | + pattern: 'https://github.com/miuix-kotlin-multiplatform/miuix/edit/main/docs/:path', |
| 82 | + text: '在 GitHub 上编辑此页面' |
| 83 | + }, |
| 84 | + |
| 85 | + footer: { |
| 86 | + message: '基于 Apache-2.0 许可发布', |
| 87 | + copyright: `版权所有 © 2024-${new Date().getFullYear()} miuix-kotlin-multiplatform` |
| 88 | + }, |
| 89 | + |
| 90 | + nav: [ |
| 91 | + { text: '首页', link: '/' }, |
| 92 | + { text: '快速开始', link: '/guide/getting-started' }, |
| 93 | + { text: '组件库', link: '/components/' }, |
| 94 | + ], |
| 95 | + |
| 96 | + sidebar: { |
| 97 | + '/guide/': [ |
| 98 | + { |
| 99 | + text: '入门', |
| 100 | + collapsed: false, |
| 101 | + items: [ |
| 102 | + { text: '快速开始', link: '/guide/getting-started' }, |
| 103 | + ] |
| 104 | + }, |
| 105 | + { |
| 106 | + text: '进阶', |
| 107 | + collapsed: false, |
| 108 | + items: [ |
| 109 | + { text: '主题系统', link: '/guide/theme' }, |
| 110 | + { text: '图标系统', link: '/guide/icons' }, |
| 111 | + { text: '工具函数', link: '/guide/utils' }, |
| 112 | + { text: '平台支持', link: '/guide/multiplatform' }, |
| 113 | + { text: '最佳实践', link: '/guide/best-practices' }, |
| 114 | + ] |
| 115 | + } |
| 116 | + ], |
| 117 | + '/components/': [ |
| 118 | + { |
| 119 | + text: '组件库', |
| 120 | + collapsed: false, |
| 121 | + items: [ |
| 122 | + { text: '总览', link: '/components/' }, |
| 123 | + ] |
| 124 | + }, |
| 125 | + { |
| 126 | + text: '脚手架', |
| 127 | + collapsed: false, |
| 128 | + items: [ |
| 129 | + { text: 'Scaffold', link: '/components/scaffold' }, |
| 130 | + ] |
| 131 | + }, |
| 132 | + { |
| 133 | + text: '基础组件', |
| 134 | + collapsed: false, |
| 135 | + items: [ |
| 136 | + { text: 'Surface', link: '/components/surface' }, |
| 137 | + { text: 'TopAppBar', link: '/components/topappbar' }, |
| 138 | + { text: 'NavigationBar', link: '/components/navigationbar' }, |
| 139 | + { text: 'TabRow', link: '/components/tabrow' }, |
| 140 | + { text: 'Card', link: '/components/card' }, |
| 141 | + { text: 'BasicComponent', link: '/components/basiccomponent' }, |
| 142 | + { text: 'Button', link: '/components/button' }, |
| 143 | + { text: 'IconButton', link: '/components/iconbutton' }, |
| 144 | + { text: 'Text', link: '/components/text' }, |
| 145 | + { text: 'SmallTitle', link: '/components/smalltitle' }, |
| 146 | + { text: 'TextField', link: '/components/textfield' }, |
| 147 | + { text: 'Switch', link: '/components/switch' }, |
| 148 | + { text: 'Checkbox', link: '/components/checkbox' }, |
| 149 | + { text: 'Slider', link: '/components/slider' }, |
| 150 | + { text: 'ProgressIndicator', link: '/components/progressindicator' }, |
| 151 | + { text: 'Icon', link: '/components/icon' }, |
| 152 | + { text: 'FloatingActionButton', link: '/components/floatingactionbutton' }, |
| 153 | + { text: 'Divider', link: '/components/divider' }, |
| 154 | + { text: 'PullToRefresh', link: '/components/pulltorefresh' }, |
| 155 | + { text: 'SearchBar', link: '/components/searchbar' }, |
| 156 | + { text: 'ColorPicker', link: '/components/colorpicker' }, |
| 157 | + { text: 'ListPopup', link: '/components/listpopup' }, |
| 158 | + ] |
| 159 | + }, |
| 160 | + { |
| 161 | + text: '特殊组件', |
| 162 | + collapsed: false, |
| 163 | + items: [ |
| 164 | + { text: 'LazyColumn', link: '/components/lazycolumn' }, |
| 165 | + ] |
| 166 | + }, |
| 167 | + { |
| 168 | + text: '扩展组件', |
| 169 | + collapsed: false, |
| 170 | + items: [ |
| 171 | + { text: 'SuperArrow', link: '/components/superarrow' }, |
| 172 | + { text: 'SuperSwitch', link: '/components/superswitch' }, |
| 173 | + { text: 'SuperCheckBox', link: '/components/supercheckbox' }, |
| 174 | + { text: 'SuperDropdown', link: '/components/superdropdown' }, |
| 175 | + { text: 'SuperSpinner', link: '/components/superspinner' }, |
| 176 | + { text: 'SuperDialog', link: '/components/superdialog' }, |
| 177 | + ] |
| 178 | + }, |
| 179 | + ] |
| 180 | + }, |
| 181 | + } |
| 182 | +}) |
0 commit comments