Skip to content

Commit

Permalink
fix(theme): fix algolia search filter
Browse files Browse the repository at this point in the history
  • Loading branch information
yyx990803 committed Oct 7, 2021
1 parent 8cbe26e commit 5fd7db2
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/client/theme-default/Layout.vue
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,9 @@ const isCustomLayout = computed(() => !!frontmatter.value.customLayout)
// home
const enableHome = computed(() => !!frontmatter.value.home)
// automatic multilang check for AlgoliaSearchBox
const isMultiLang = computed(() => Object.keys(site.value.langs).length > 1)
// navbar
const showNavbar = computed(() => {
const themeConfig = theme.value
Expand Down Expand Up @@ -85,7 +88,7 @@ const pageClasses = computed(() => {
<AlgoliaSearchBox
v-if="theme.algolia"
:options="theme.algolia"
:multilang="!!theme.locales"
:multilang="isMultiLang"
/>
</slot>
</template>
Expand Down

0 comments on commit 5fd7db2

Please sign in to comment.