en.mts 5.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222
  1. import { type DefaultTheme, defineConfig } from 'vitepress';
  2. import { version } from '../../../package.json';
  3. export const en = defineConfig({
  4. description: 'Vben Admin & Enterprise level management system framework',
  5. lang: 'en-US',
  6. themeConfig: {
  7. darkModeSwitchLabel: 'Theme',
  8. darkModeSwitchTitle: 'Switch to Dark Mode',
  9. docFooter: {
  10. next: 'Next Page',
  11. prev: 'Previous Page',
  12. },
  13. editLink: {
  14. pattern:
  15. 'https://github.com/vbenjs/vue-vben-admin/edit/main/docs/src/:path',
  16. text: 'Edit this page on GitHub',
  17. },
  18. footer: {
  19. copyright: `Copyright © 2020-${new Date().getFullYear()} Vben`,
  20. message: 'Released under the MIT License.',
  21. },
  22. langMenuLabel: 'Language',
  23. lastUpdated: {
  24. formatOptions: {
  25. dateStyle: 'short',
  26. timeStyle: 'medium',
  27. },
  28. text: 'Last updated on',
  29. },
  30. lightModeSwitchTitle: 'Switch to Light Mode',
  31. nav: nav(),
  32. outline: {
  33. label: 'Navigate',
  34. },
  35. returnToTopLabel: 'Back to top',
  36. sidebar: {
  37. '/en/commercial/': {
  38. base: '/en/commercial/',
  39. items: sidebarCommercial(),
  40. },
  41. '/en/guide/': { base: '/en/guide/', items: sidebarGuide() },
  42. },
  43. },
  44. });
  45. function sidebarGuide(): DefaultTheme.SidebarItem[] {
  46. return [
  47. {
  48. collapsed: false,
  49. text: 'Introduction',
  50. items: [
  51. {
  52. link: 'introduction/vben',
  53. text: 'About Vben Admin',
  54. },
  55. {
  56. link: 'introduction/why',
  57. text: 'Why Choose Us?',
  58. },
  59. { link: 'introduction/quick-start', text: 'Quick Start' },
  60. { link: 'introduction/thin', text: 'Lite Version' },
  61. ],
  62. },
  63. {
  64. text: 'Basics',
  65. items: [
  66. { link: 'essentials/concept', text: 'Basic Concepts' },
  67. { link: 'essentials/development', text: 'Local Development' },
  68. { link: 'essentials/route', text: 'Routing and Menu' },
  69. { link: 'essentials/settings', text: 'Configuration' },
  70. { link: 'essentials/icons', text: 'Icons' },
  71. { link: 'essentials/styles', text: 'Styles' },
  72. { link: 'essentials/external-module', text: 'External Modules' },
  73. { link: 'essentials/build', text: 'Build and Deployment' },
  74. { link: 'essentials/server', text: 'Server Interaction and Data Mock' },
  75. ],
  76. },
  77. {
  78. text: 'Advanced',
  79. items: [
  80. { link: 'in-depth/login', text: 'Login' },
  81. { link: 'in-depth/theme', text: 'Theme' },
  82. { link: 'in-depth/access', text: 'Access Control' },
  83. { link: 'in-depth/locale', text: 'Internationalization' },
  84. { link: 'in-depth/features', text: 'Common Features' },
  85. { link: 'in-depth/check-updates', text: 'Check Updates' },
  86. { link: 'in-depth/loading', text: 'Global Loading' },
  87. { link: 'in-depth/ui-framework', text: 'UI Framework Switching' },
  88. ],
  89. },
  90. {
  91. text: 'Engineering',
  92. items: [
  93. { link: 'project/standard', text: 'Standards' },
  94. { link: 'project/cli', text: 'CLI' },
  95. { link: 'project/dir', text: 'Directory Explanation' },
  96. { link: 'project/test', text: 'Unit Testing' },
  97. { link: 'project/tailwindcss', text: 'Tailwind CSS' },
  98. { link: 'project/changeset', text: 'Changeset' },
  99. { link: 'project/vite', text: 'Vite Config' },
  100. ],
  101. },
  102. {
  103. text: 'Others',
  104. items: [
  105. { link: 'other/project-update', text: 'Project Update' },
  106. { link: 'other/remove-code', text: 'Remove Code' },
  107. { link: 'other/faq', text: 'FAQ' },
  108. ],
  109. },
  110. ];
  111. }
  112. function sidebarCommercial(): DefaultTheme.SidebarItem[] {
  113. return [
  114. {
  115. link: 'community',
  116. text: 'Community',
  117. },
  118. {
  119. link: 'technical-support',
  120. text: 'Technical-support',
  121. },
  122. {
  123. link: 'customized',
  124. text: 'Customized',
  125. },
  126. ];
  127. }
  128. function nav(): DefaultTheme.NavItem[] {
  129. return [
  130. {
  131. text: 'Doc',
  132. items: [
  133. {
  134. link: '/en/guide/introduction/vben',
  135. text: 'Guide',
  136. },
  137. {
  138. text: 'Historical Versions',
  139. items: [
  140. {
  141. link: 'https://doc.vvbin.cn',
  142. text: '2.x Version Documentation',
  143. },
  144. ],
  145. },
  146. ],
  147. },
  148. {
  149. text: 'Demo',
  150. items: [
  151. {
  152. text: 'Vben Admin',
  153. items: [
  154. {
  155. link: 'https://www.vben.pro',
  156. text: 'Demo Version',
  157. },
  158. {
  159. link: 'https://ant.vben.pro',
  160. text: 'Ant Design Vue Version',
  161. },
  162. {
  163. link: 'https://naive.vben.pro',
  164. text: 'Naive Version',
  165. },
  166. {
  167. link: 'https://ele.vben.pro',
  168. text: 'Element Plus Version',
  169. },
  170. ],
  171. },
  172. {
  173. text: 'Others',
  174. items: [
  175. {
  176. link: 'https://vben.vvbin.cn',
  177. text: 'Vben Admin 2.x',
  178. },
  179. ],
  180. },
  181. ],
  182. },
  183. {
  184. text: version,
  185. items: [
  186. {
  187. link: 'https://github.com/vbenjs/vue-vben-admin/releases',
  188. text: 'Changelog',
  189. },
  190. {
  191. link: 'https://github.com/orgs/vbenjs/projects/5',
  192. text: 'Roadmap',
  193. },
  194. {
  195. link: 'https://github.com/vbenjs/vue-vben-admin/blob/main/.github/contributing.md',
  196. text: 'Contribution',
  197. },
  198. ],
  199. },
  200. {
  201. link: '/commercial/technical-support',
  202. text: '🦄 Tech Support',
  203. },
  204. {
  205. link: '/sponsor/personal',
  206. text: '✨ Sponsor',
  207. },
  208. {
  209. link: '/commercial/community',
  210. text: '👨‍👦‍👦 Community',
  211. },
  212. {
  213. link: '/friend-links/',
  214. text: '🤝 Friend Links',
  215. },
  216. ];
  217. }