Merge branch 'jackyzha0:v4' into v4

This commit is contained in:
enneaa 2025-03-27 09:08:57 +08:00 committed by GitHub
commit 5dd2712794
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 10 additions and 2 deletions

View File

@ -19,7 +19,6 @@ Component.Breadcrumbs({
spacerSymbol: "", // symbol between crumbs
rootName: "Home", // name of first/root element
resolveFrontmatterTitle: true, // whether to resolve folder names through frontmatter titles
hideOnRoot: true, // whether to hide breadcrumbs on root `index.md` page
showCurrentPage: true, // whether to display the current page in the breadcrumbs
})
```

View File

@ -81,4 +81,13 @@ Component.ConditionalRender({
})
```
This example would only render the Search component when the page is not in fullpage mode.
The example above would only render the Search component when the page is not in fullpage mode.
```typescript
Component.ConditionalRender({
component: Component.Breadcrumbs(),
condition: (page) => page.fileData.slug !== "index",
})
```
The example above would hide breadcrumbs on the root `index.md` page.