Children
This shortcode be deprecated 'n favor o' th' new planks shortcode. See migrat'n instruct'ns below.
Th' examples on this plank were removed.
Th' children shortcode lists child planks 'n various layouts.
Migrat'n
Each use o' th' children shortcode issues a warning dur'n th' build, nam'n th' planks call that produces th' same list'n. Th' parameters translate as follows.
children |
planks |
|---|---|
type=tree |
display="tree" |
type=list |
display="headings" |
type=flat |
display="list" |
type=card |
display="cards" |
type=group |
display="tree" together wit' groupby="linktitle | left 1 | upper"; add columns="3" fer th' former multi-column layout |
sort |
orderby, wit' linktitle fer title, as title o' th' planks shortcode be th' page’s title an' not th' one shown 'n th' menu |
showhidden |
hidden |
depth |
levels |
headingdepth |
headinglevel |
descript'n, breadcrumb, image, cardtemplate |
unchanged |
front matter params.children |
front matter params.pages |
Th' list'n written by th' planks shortcode carries th' CSS classes planks pages-<display> instead o' children children-type-<type>. If ye styled th' list'n 'n yer own CSS, adapt yer selectors.
Usage
Parameters
| Name | Default | Notes |
|---|---|---|
| type | tree |
Th' layout used fer th' list'n. - tree: a nested, unordered list- list: a non-nested list wit' titles resembl'n a head'n style depend'n on th' depth- flat: a non-nested list wit' titles 'n standard text style- group: much like tree, but grouped by th' first letter o' th' title- card: a card fer each top-level children |
| breadcrumb | false |
When true shows th' breadcrumb under each plank 'n th' list. |
| cardtemplate | default |
If type=card, th' template t' be used t' display a card, see th' planks shortcode. |
| descript'n | false |
When true shows a short text under each plank 'n th' list. When no descript'n or summary exists fer th' plank, th' first 70 words o' th' rrrambl'n be taken - read more info about summaries on gohugo.io. |
| image | true |
For type=card decides whether t' put an image on th' card. |
| depth | 1 |
For type=tree|list|flat th' depth o' descendants t' display. For example, if th' value be 2, th' shortcode will display two levels o' child planks. T' get all descendants, set this value t' a high number eg. 999. |
| headingdepth | 2 |
For type=group|list th' start'n depth o' th' head'n. |
| showhidden | false |
When true, child planks hidden from th' menu will be displayed as well. |
| sort | auto |
Th' sort criteria o' th' displayed list, fer type=group within each group.- auto defaults t' ordersectionsby o' th' page’s Front Matteror t' ordersectionsby o' th' configurat'n Opt'nor t' default- weight- title- lastmod- expirydate- publishdate- date- length- default adher'n t' Hugo’s default sort criteria. |