Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
B
book
Manage
Activity
Members
Labels
Plan
Wiki
Custom issue tracker
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Model registry
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
project
book
Commits
77bf1035
Commit
77bf1035
authored
8 months ago
by
Liam Morland
Browse files
Options
Downloads
Patches
Plain Diff
Issue
#3445783
by Liam Morland: Add item prefix, infix, and suffix to book-tree template
parent
a448c269
No related branches found
No related tags found
1 merge request
!2
Issue #3445783 by Liam Morland: Add item prefix, infix, and suffix to book-tree template
Pipeline
#273635
passed
4 months ago
Stage: build
Stage: validate
Stage: test
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
templates/book-tree.html.twig
+6
-0
6 additions, 0 deletions
templates/book-tree.html.twig
with
6 additions
and
0 deletions
templates/book-tree.html.twig
+
6
−
0
View file @
77bf1035
...
...
@@ -16,6 +16,9 @@
* - is_collapsed: TRUE if the link has children within the current book tree
* that are not currently visible.
* - in_active_trail: TRUE if the link is in the active trail.
* - prefix: Display before the item.
* - infix: Display in the item between the link and the child items.
* - suffix: Display after the item.
*
* @ingroup themeable
*/
...
...
@@ -38,10 +41,13 @@
{%
endif
%}
{%
for
item
in
items
%}
<li
{{
item.attributes
}}
>
{{
item.prefix
}}
{{
link
(
item.title
,
item.url
)
}}
{{
item.infix
}}
{%
if
item.below
%}
{{
book_tree.book_links
(
item.below
,
attributes
,
menu_level
+
1
)
}}
{%
endif
%}
{{
item.suffix
}}
</li>
{%
endfor
%}
</ul>
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment