Skip to content

Commit

Permalink
fix: documate style
Browse files Browse the repository at this point in the history
  • Loading branch information
JuckZ committed Oct 24, 2023
1 parent b7117fe commit 8d54b74
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 0 deletions.
1 change: 1 addition & 0 deletions docs/.vitepress/config/index.ts
Expand Up @@ -31,6 +31,7 @@ export default defineConfig({
// link: 'https://abm-zh-tw.netlify.app',
// }
},
markdown: {},
sitemap: {
hostname: 'https://abm.timesavior.io'
},
Expand Down
6 changes: 6 additions & 0 deletions docs/.vitepress/theme/index.ts
Expand Up @@ -23,6 +23,11 @@ export default {
// https://vitepress.dev/guide/extending-default-theme#layout-slots
'nav-bar-content-before': () => h(Documate, {
endpoint: 'https://f965a6vcks.us.aircode.run/ask',
predefinedQuestions: [
'What is Awesome Brain Manager?',
'How to use Awesome Brain Manager?',
"What features Awesome Brain Manager have?"
]
}),
})
},
Expand All @@ -32,6 +37,7 @@ export default {
router.onBeforePageLoad = (to) => {
if (import.meta.env.DEV) return
const url = 'https://api.gumengya.com/Api/UserInfo'
// FIXME 每次构建都会执行,而不是进入路由时执行?
fetch(url, {
method: "get",
mode: 'cors',
Expand Down
4 changes: 4 additions & 0 deletions docs/.vitepress/theme/style.css
Expand Up @@ -137,3 +137,7 @@
--docsearch-primary-color: var(--vp-c-brand-1) !important;
}

/* fix Documate style */
.combobox-options .markdown-body {
background-color: transparent;
}

0 comments on commit 8d54b74

Please sign in to comment.