\n\n\u003Cimg width=\"298\" height=\"300\" alt=\"Image\" src=\"https://github.com/user-attachments/assets/273a285b-18d3-4f36-9322-73976c96a70a\" />\n\n### Expected behavior\n\n1. `lang` attribute (e.g. `lang=zh-CN` or `lang=ja`) is added to one of ancestor tags of each language label\n2. Each han is displayed as the correct/expected form\n\nCorrect:\n\nSet the correct `lang` attribute values to Simplified/Traditional Chinese labels:\n\n\u003Cimg width=\"343\" height=\"719\" alt=\"Image\" src=\"https://github.com/user-attachments/assets/4d93fc69-2bd5-45c1-a1ae-ee4c23a14846\" />\n\n↓Note: Japanese \u003Cspan lang=ja>文\u003C/span> is prioritized due to `system-ui` and `ui-sans-serif`, so this is not ideal:\n\n\u003Cimg width=\"247\" height=\"183\" alt=\"Image\" src=\"https://github.com/user-attachments/assets/6c24d586-1317-45f5-a355-29cf048206f0\" />\n\n(`sans-serif` instead of them will fix the shape of 文)\n\n### System Info\n\n```Text\nN/A\n```\n\n### Additional context\n\n_No response_\n\n### Validations\n\n- [x] Check if you're on the [latest VitePress version](https://github.com/vuejs/vitepress/releases/latest).\n- [x] Follow our [Code of Conduct](https://vuejs.org/about/coc.html)\n- [x] Read the [docs](https://vitepress.dev).\n- [x] Check that there isn't already an issue that reports the same bug to avoid creating a duplicate.",[3151],{"name":3152,"color":3153},"bug: pending triage","e99695",4927,"vuejs","vitepress","open","Set `lang` attribute to language labels","2025-08-31T14:33:37Z","https://github.com/vuejs/vitepress/issues/4927",0.7632245,{"description":3163,"labels":3164,"number":3168,"owner":3155,"repository":3156,"state":3169,"title":3170,"updated_at":3171,"url":3172,"score":3173},"### Discussed in https://github.com/vuejs/vitepress/discussions/1368\r\n\r\n\u003Cdiv type='discussions-op-text'>\r\n\r\n\u003Csup>Originally posted by **Zogsha** September 19, 2022\u003C/sup>\r\nHi, thanks for your work on vitepress!\r\n\r\nMy documentation site is written in French, so I need the Docsearch component in French.\r\n\r\nI have two problems :\r\n\r\n1. There is a `algolia.buttonText` option in `themeConfig`. I set it to \"Rechercher\" instead of the default \"Search\", but whenever I click on the search component or use \"CTRL+K\", the placeholder turns back to \"Search\". It only displays \"Rechercher\" when the page refreshes. I only tested in dev.\r\n\r\n2. In the Docsearch API Reference, there is `translations` option (https://docsearch.algolia.com/docs/api#translations). I can't figure out how to configure it.\r\n\r\nI think __1.__ is not intended, but I didn't look further. Is __2.__ intended ? If that is the case, do you plan to let us translate the Doscsearch modal via `algolia` config in `themeConfig`?\r\n\r\nThanks,\r\nAliosha\u003C/div>",[3165],{"name":3166,"color":3167},"theme","0754FB",1381,"closed","[i18n] allow translating docsearch labels","2023-01-25T00:04:21Z","https://github.com/vuejs/vitepress/issues/1381",0.7053698,{"description":3175,"labels":3176,"number":3180,"owner":3155,"repository":3156,"state":3169,"title":3181,"updated_at":3182,"url":3183,"score":3184},"### Describe the bug\r\n\r\nThe search button and dialog should use semantic markup: roles and aria attributes\r\n\r\n### Reproduction\r\n\r\nhttps://unocss.dev/\r\n\r\n### Expected behavior\r\n\r\nJust check Algolia search button and dialog on VP docs.\r\n\r\n### System Info\r\n\r\n```shell\r\nNA\r\n```\r\n\r\n\r\n### Additional context\r\n\r\n_No response_\r\n\r\n### Validations\r\n\r\n- [X] Follow our [Code of Conduct](https://vuejs.org/about/coc.html)\r\n- [X] Read the [docs](https://vitepress.dev).\r\n- [X] Check that there isn't already an issue that reports the same bug to avoid creating a duplicate.",[3177],{"name":3178,"color":3179},"a11y","fbca04",2232,"Local search: review html markup, should be semantic","2023-06-18T00:04:56Z","https://github.com/vuejs/vitepress/issues/2232",0.71343374,{"description":3186,"labels":3187,"number":3191,"owner":3155,"repository":3156,"state":3169,"title":3192,"updated_at":3193,"url":3194,"score":3195},"### Is your feature request related to a problem? Please describe.\n\nI configured the configuration prompted by the official website, but it did not work.Is there something wrong with the configuration, or missing.\r\n``` js\r\nimport { defineConfig } from 'vitepress'\r\n\r\nexport default defineConfig({\r\n lang: 'zh',\r\n locales: {\r\n root: {\r\n label: 'Chinese',\r\n lang: 'zh',\r\n },\r\n },\r\n themeConfig: {\r\n search: {\r\n provider: 'local',\r\n options: {\r\n locales: {\r\n zh: {\r\n translations: {\r\n button: {\r\n buttonText: '搜索文档',\r\n buttonAriaLabel: '搜索文档'\r\n },\r\n modal: {\r\n noResultsText: '无法找到相关结果',\r\n resetButtonTitle: '清除查询条件',\r\n footer: {\r\n selectText: '选择',\r\n navigateText: '切换'\r\n }\r\n }\r\n }\r\n }\r\n }\r\n }\r\n }\r\n }\r\n})\r\n```\n\n### Describe the solution you'd like\n\nit can work properly,or give me a demo\n\n### Describe alternatives you've considered\n\n_No response_\n\n### Additional context\n\n_No response_\n\n### Validations\n\n- [X] Follow our [Code of Conduct](https://vuejs.org/about/coc.html)\n- [X] Read the [docs](https://vitepress.dev).\n- [X] Read the [Contributing Guidelines](https://github.com/vuejs/vitepress/blob/main/.github/contributing.md).\n- [X] Check that there isn't already an issue that asks for the same feature to avoid creating a duplicate.",[3188],{"name":3189,"color":3190},"question","5D5FAE",2271,"local search : I want to configure the local search prompt as Chinese, how should I configure it?","2023-04-29T00:03:38Z","https://github.com/vuejs/vitepress/issues/2271",0.71385074,{"description":3197,"labels":3198,"number":3200,"owner":3155,"repository":3156,"state":3169,"title":3201,"updated_at":3202,"url":3203,"score":3204},"The Algolia search component no longer seems to return any results; this includes the VitePress docs themselves:\r\n\r\nhttps://vitepress.vuejs.org/\r\n\r\nI suspect something might be going wrong in terms of passing the API key / index name down to the Algolia DocSearch component.",[3199],{"name":3152,"color":3153},316,"Algolia search no longer seems to be working","2023-01-21T16:22:20Z","https://github.com/vuejs/vitepress/issues/316",0.72928834,{"description":3206,"labels":3207,"number":3212,"owner":3155,"repository":3156,"state":3169,"title":3213,"updated_at":3214,"url":3215,"score":3216},"### Describe the bug\n\nHello, when I was searching using Algolia, the search results on the vitepress page were not displayed. However, Algolia's console page showed 140 records. Is this a missing configuration? By the way, for the project reason, I didn't use docsearch, but Algolia's build plan\n\n### Reproduction\n\nThe error can be seen on this website https://stackblitz.com/edit/vite-48o9dv?file=docs%2F.vitepress%2Fconfig.ts,package.json\r\nThis is the source code of the website https://github.com/galgaxy3/docs-demo\n\n### Expected behavior\n\nThere should be a query result\n\n### System Info\n\n```Text\nChrome, vitepress 1.0.0-rc.44\n```\n\n\n### Additional context\n\n_No response_\n\n### Validations\n\n- [X] Check if you're on the [latest VitePress version](https://github.com/vuejs/vitepress/releases/latest).\n- [X] Follow our [Code of Conduct](https://vuejs.org/about/coc.html)\n- [X] Read the [docs](https://vitepress.dev).\n- [x] Check that there isn't already an issue that reports the same bug to avoid creating a duplicate.",[3208,3209],{"name":3189,"color":3190},{"name":3210,"color":3211},"stale","ededed",3614,"Algolia search result is empty","2024-04-28T12:24:52Z","https://github.com/vuejs/vitepress/issues/3614",0.732463,{"description":3218,"labels":3219,"number":3221,"owner":3155,"repository":3156,"state":3169,"title":3222,"updated_at":3223,"url":3224,"score":3225},"### Describe the bug\n\nHere is my configuration\r\nmy website: https://lark-base-team.github.io/js-sdk-docs/\r\n```\r\nimport { defineConfig } from 'vitepress'\r\nimport { getZhSideBar } from './zh-sidebar';\r\nimport { getEnSideBar } from './en-sidebar';\r\n\r\n\r\n// https://vitepress.dev/reference/site-config\r\nexport default defineConfig({\r\n lastUpdated: true,\r\n cleanUrls: true,\r\n base: '/js-sdk-docs/',\r\n themeConfig: {\r\n logo: '/logo.svg',\r\n search: {\r\n provider: 'local'\r\n },\r\n nav: [\r\n { text: 'API', link: '/zh/api/guide', activeMatch: 'zh/api' },\r\n ],\r\n },\r\n head: [\r\n ['link', { rel: 'icon', href: '/js-sdk-docs/logo.svg' }],\r\n ],\r\n title: 'Base JS SDK',\r\n description: 'Base JS SDK Docs',\r\n // sitemap: {\r\n // hostname: 'https://basejsapi.com',\r\n // },\r\n lang: 'zh',\r\n locales: {\r\n zh: {\r\n label: '中文',\r\n lang: 'zh',\r\n dir: '/zh',\r\n title: 'Base JS SDK',\r\n description: 'Base JS SDK Docs',\r\n themeConfig: {\r\n logo: '/logo.svg',\r\n search: {\r\n provider: 'local'\r\n },\r\n nav: [\r\n { text: 'API', link: '/zh/api/guide', activeMatch: 'zh/api' },\r\n ],\r\n\r\n sidebar: getZhSideBar(),\r\n },\r\n },\r\n en: {\r\n label: 'English',\r\n lang: 'en',\r\n dir: '/en',\r\n title: 'Base JS SDK',\r\n description: 'Base JS SDK Docs',\r\n themeConfig: {\r\n logo: '/logo.svg',\r\n search: {\r\n provider: 'local'\r\n },\r\n nav: [\r\n { text: 'API', link: '/en/api/guide.md' },\r\n ],\r\n sidebar: getEnSideBar(),\r\n },\r\n }\r\n },\r\n})\r\n\r\n```\n\n### Reproduction\n\nlike my config\n\n### Expected behavior\n\nI hope to demonstrate the ability to switch languages.\n\n### System Info\n\n```Text\nSystem:\r\n OS: macOS 13.6\r\n CPU: (10) arm64 Apple M1 Pro\r\n Memory: 208.28 MB / 32.00 GB\r\n Shell: 5.9 - /bin/zsh\r\n Binaries:\r\n Node: 18.14.2 - ~/.nvm/versions/node/v18.14.2/bin/node\r\n Yarn: 1.22.19 - /opt/homebrew/bin/yarn\r\n npm: 9.5.0 - ~/.nvm/versions/node/v18.14.2/bin/npm\r\n pnpm: 8.7.4 - ~/.nvm/versions/node/v18.14.2/bin/pnpm\r\n Browsers:\r\n Chrome: 118.0.5993.70\r\n Safari: 17.0\r\n npmPackages:\r\n vitepress: 1.0.0-rc.10 => 1.0.0-rc.10\n```\n\n\n### Additional context\n\n_No response_\n\n### Validations\n\n- [X] Check if you're on the [latest VitePress version](https://github.com/vuejs/vitepress/releases/latest).\n- [X] Follow our [Code of Conduct](https://vuejs.org/about/coc.html)\n- [X] Read the [docs](https://vitepress.dev).\n- [X] Check that there isn't already an issue that reports the same bug to avoid creating a duplicate.",[3220],{"name":3189,"color":3190},3099,"The homepage lacks the ability to switch languages. ","2023-10-27T00:04:14Z","https://github.com/vuejs/vitepress/issues/3099",0.7376,{"description":3227,"labels":3228,"number":3229,"owner":3155,"repository":3156,"state":3169,"title":3230,"updated_at":3231,"url":3232,"score":3233},"### Describe the bug\r\n\r\nI am experiencing an issue with the integrated search component (Algolia).\r\nThe search function is not working properly, as it returns **zero results** when I use the web interface in my recently created project with Vitepress. \r\n\r\nHowever, if I perform a search using the API or on Algolia's website, the search function works correctly and returns results.\r\n\r\nIt's possible that there may be an issue with the search component in Vitepress that's causing this problem. \r\n\r\nI wanted to bring this to your attention in the hopes that it can be addressed and fixed as soon as possible. \r\n\r\n### Reproduction\r\n\r\n- Create an Algolia account\r\n- Configure the algolia section with index, API key and app id.\r\n - ```\r\n appId: '5D6FRGxxxx', \r\n apiKey: 'e04451b589c484090xxxxxxxxxxxxxxx', \r\n indexName: 'csspills'\r\n ```\r\n- Create the index (both manually / via API)\r\n - ```\r\n [\r\n {\r\n title: 'Pill 1 CLI',\r\n description: 'Create a new project with the CLI',\r\n tags: [ 'demo1', 'cli' ]\r\n },\r\n {\r\n title: 'Pill 2 AWS',\r\n description: 'Create a new AWS project from the command line',\r\n tags: [ 'demo2', 'AWS' ]\r\n }\r\n ]\r\n ```\r\n- Start the local server\r\n- Search \r\n\r\n\r\n\r\n\r\n### Expected behavior\r\n\r\nShow results after searching\r\n\r\n### System Info\r\n\r\n```shell\r\nSystem:\r\n OS: macOS 13.2.1\r\n CPU: (8) x64 Apple M1\r\n Memory: 7.73 MB / 16.00 GB\r\n Shell: 5.8.1 - /bin/zsh\r\n Binaries:\r\n Node: 16.13.2 - ~/.nvm/versions/node/v16.13.2/bin/node\r\n Yarn: 1.22.19 - /opt/homebrew/bin/yarn\r\n npm: 8.1.2 - ~/.nvm/versions/node/v16.13.2/bin/npm\r\n Browsers:\r\n Brave Browser: 107.1.45.133\r\n Chrome: 109.0.5414.119\r\n Chrome Canary: 112.0.5609.0\r\n Firefox: 95.0.2\r\n Firefox Developer Edition: 108.0\r\n Safari: 16.3\r\n```\r\n\r\n\r\n### Additional context\r\n\r\nUI Request: \r\n```\r\nhttps://5d6frgc6t9-dsn.algolia.net/1/indexes/*/queries?x-algolia-agent=Algolia%20for%20JavaScript%20(4.8.5)%3B%20Browser%20(lite)%3B%20docsearch%20(3.3.3)%3B%20docsearch-react%20(3.3.3)%3B%20docsearch.js%20(3.3.3)&x-algolia-api-key=e04451b589c484090xxxxxxxxxxxxxxx&x-algolia-application-id=5D6FRGxxxx\r\n```\r\nRequest Method: `POST`\r\nStatus Code: `200 OK`\r\n\r\n\r\n\r\nAPI Request (Node.js)\r\n\r\n\r\n```\r\n{\r\n hits: [\r\n {\r\n title: 'Pill 2 AWS',\r\n description: 'Create a new AWS project from the command line',\r\n tags: [Array],\r\n objectID: '85344354000',\r\n _highlightResult: [Object]\r\n }\r\n ],\r\n nbHits: 1,\r\n page: 0,\r\n nbPages: 1,\r\n hitsPerPage: 20,\r\n exhaustiveNbHits: true,\r\n exhaustiveTypo: true,\r\n exhaustive: { nbHits: true, typo: true },\r\n query: 'AWS',\r\n params: 'query=AWS',\r\n renderingContent: {},\r\n processingTimeMS: 1,\r\n processingTimingsMS: {\r\n getIdx: { load: [Object], total: 1 },\r\n request: { roundTrip: 30 },\r\n total: 1\r\n },\r\n serverTimeMS: 1\r\n}\r\n```\r\n\r\n### Validations\r\n\r\n- [X] Follow our [Code of Conduct](https://vuejs.org/about/coc.html)\r\n- [X] Read the [docs](https://vitepress.vuejs.org).\r\n- [X] Check that there isn't already an issue that reports the same bug to avoid creating a duplicate.",[],1970,"Algolia search is broken","2023-03-03T12:16:55Z","https://github.com/vuejs/vitepress/issues/1970",0.7384385,{"description":3235,"labels":3236,"number":3238,"owner":3155,"repository":3156,"state":3169,"title":3239,"updated_at":3240,"url":3241,"score":3242},"### Is your feature request related to a problem? Please describe.\n\n Algolia Search : transformItems not work.\r\n\r\n\r\n\r\n\r\n\n\n### Describe the solution you'd like\n\nI want http://hostname/prefix/guide/ -> http://hostname/guide/\r\n\n\n### Describe alternatives you've considered\n\n_No response_\n\n### Additional context\n\n_No response_\n\n### Validations\n\n- [X] Follow our [Code of Conduct](https://vuejs.org/about/coc.html)\n- [X] Read the [docs](https://vitepress.vuejs.org).\n- [X] Read the [Contributing Guidelines](https://github.com/vuejs/vitepress/blob/main/.github/contributing.md).\n- [X] Check that there isn't already an issue that asks for the same feature to avoid creating a duplicate.",[3237],{"name":3166,"color":3167},614," Algolia Search : transformItems not work","2023-01-21T14:16:55Z","https://github.com/vuejs/vitepress/issues/614",0.741465,{"description":3244,"labels":3245,"number":3246,"owner":3155,"repository":3156,"state":3169,"title":3247,"updated_at":3248,"url":3249,"score":3250},"After configuring according to the document, after clicking the search, \"#VPContent\" will be added after the original link and will not jump to the search result, as shown in the figure.\r\n\u003Cimg src=https://cdn.jsdelivr.net/gh/vanhiupun/pic@1.0/img/202309112316868.png width=60% />\r\n```yaml\r\n // algolia搜索\r\n search: {\r\n provider: 'algolia',\r\n options: {\r\n appId: 'xxxxx',\r\n apiKey: 'xxxxx',\r\n indexName: 'xxxxxx'\r\n }\r\n },",[],2944,"\"Algolia Search\" cannot jump to the page","2023-09-21T00:04:13Z","https://github.com/vuejs/vitepress/issues/2944",0.7443608,["Reactive",3252],{},["Set"],["ShallowReactive",3255],{"$fTRc1wZytZ_XrK4EfJfei_Sz-An4H4Yy6syhVxH_PVJc":-1,"$fE7WD16D4Lp1CJAiuTPzwXjlh1TRAMVWwmKt2sDRSyH4":-1},"/vuejs/vitepress/796"]