mirror of
https://github.com/jackyzha0/quartz.git
synced 2025-05-18 06:24:22 +02:00
Updating breadcrumbs docs on ConditionalRender (#1871)
Some checks failed
Build and Test / build-and-test (ubuntu-latest) (push) Has been skipped
Build and Test / publish-tag (push) Has been skipped
Build and Test / build-and-test (macos-latest) (push) Has been cancelled
Build and Test / build-and-test (windows-latest) (push) Has been cancelled
Some checks failed
Build and Test / build-and-test (ubuntu-latest) (push) Has been skipped
Build and Test / publish-tag (push) Has been skipped
Build and Test / build-and-test (macos-latest) (push) Has been cancelled
Build and Test / build-and-test (windows-latest) (push) Has been cancelled
This commit is contained in:
parent
23b691f38c
commit
b397dae951
@ -19,7 +19,6 @@ Component.Breadcrumbs({
|
|||||||
spacerSymbol: "❯", // symbol between crumbs
|
spacerSymbol: "❯", // symbol between crumbs
|
||||||
rootName: "Home", // name of first/root element
|
rootName: "Home", // name of first/root element
|
||||||
resolveFrontmatterTitle: true, // whether to resolve folder names through frontmatter titles
|
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
|
showCurrentPage: true, // whether to display the current page in the breadcrumbs
|
||||||
})
|
})
|
||||||
```
|
```
|
||||||
|
@ -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.
|
||||||
|
Loading…
x
Reference in New Issue
Block a user