Difference between revisions of "Template:Chapter navigation"
From Venlo Samenwerkingswijzer
(Created page with "<noinclude> This is the "Chapter navigation" template. It should be called in the following format: <pre> {{Chapter navigation }} </pre> Edit the page to see the template text...") |
|||
(20 intermediate revisions by the same user not shown) | |||
Line 3: | Line 3: | ||
It should be called in the following format: | It should be called in the following format: | ||
<pre> | <pre> | ||
− | {{Chapter navigation | + | {{Chapter navigation}} |
− | }} | ||
</pre> | </pre> | ||
Edit the page to see the template text. | Edit the page to see the template text. | ||
− | </noinclude><includeonly>{| class=" | + | </noinclude><includeonly><!--- |
− | |} | + | |
− | </includeonly> | + | # Setting values |
+ | |||
+ | --->{{#vardefine:@topic|{{BASEPAGENAME}} }}<!--- | ||
+ | --->{{#vardefine:@section|{{#ask:[[Item::{{PAGENAME}}]] [[Belongs to section::+]]|?Belongs to section=|link=none|mainlabel=-|headers=plain|limit=1}} }}<!--- | ||
+ | --->{{#vardefine:@section is topic|{{#ifeq:{{#var:@section}}|{{#var:@topic}}|yes|no}} }}<!--- | ||
+ | |||
+ | # Body | ||
+ | |||
+ | ---><div class="panel panel-default" style="background-color: #f6f6f6; padding: .5em;"> | ||
+ | <div class="row"> | ||
+ | <div class="col-xs-10"> | ||
+ | {{#switch:{{#var:@section is topic}} | ||
+ | |yes=<big>[[{{#var:@topic}}]]</big> | ||
+ | |no=<big>[[{{#var:@topic}}]]</big> | ||
+ | <h5 style="padding-left: .5em">[[{{#var:@topic}}#{{#var:@section}}|{{#var:@section}}]]</h5> | ||
+ | }} | ||
+ | </div> | ||
+ | <div class="col-xs-2" style="text-align:right">{{Fa|compass fa-2x|Style=color:grey;}}</div> | ||
+ | </div> | ||
+ | <div class="row"> | ||
+ | <div class="col-md-12"> | ||
+ | {{#ask: [[Item ordened in::{{#var:@topic}}]] [[Belongs to section::{{#var:@section}}]] | ||
+ | |?Item | ||
+ | |?Item ordened in | ||
+ | |sort=Ordernumber | ||
+ | |format=template | ||
+ | |template=Show table of contents/Chapter | ||
+ | |named args=yes | ||
+ | |link=none | ||
+ | }}</div></div></div></includeonly> |
Latest revision as of 11:33, 9 November 2016
This is the "Chapter navigation" template. It should be called in the following format:
{{Chapter navigation}}
Edit the page to see the template text.