Jump to content

Template:ReportTOC: Difference between revisions

From ClimateKG
No edit summary
No edit summary
Line 1: Line 1:
<onlyinclude><div class="rtoc-box">
<noinclude>
<div class="rtoc-header">Contents</div>
== ReportTOC Template ==
 
This template creates a styled table of contents for reports with sections for SPM, Technical Summary, Chapters, and Annexes.
<div class="s-fm">
<div class="rtoc-section-title">Front Matter</div>
<div class="rtoc-oos">Content in this section is out of scope</div>
</div>
 
<div class="s-spm">
<div class="rtoc-section-title">SPM</div>
{{#if:{{{spmtitle|}}}|<div class="rtoc-entry"><div class="rtoc-entry-text"><span class="rtoc-entry-title">{{{spmtitle}}}</span>{{#if:{{{spmsubtitle|}}}|<span class="rtoc-entry-subtitle">{{{spmsubtitle}}}</span>}}</div><span class="rtoc-read">[[{{{spmurl}}}|Read]]</span></div>}}
</div>
 
<div class="s-ts">
<div class="rtoc-section-title">TS</div>
{{#if:{{{tstitle|}}}|<div class="rtoc-entry"><div class="rtoc-entry-text"><span class="rtoc-entry-title">{{{tstitle}}}</span>{{#if:{{{tssubtitle|}}}|<span class="rtoc-entry-subtitle">{{{tssubtitle}}}</span>}}</div><span class="rtoc-read">[[{{{tsurl}}}|Read]]</span></div>}}
</div>


<div class="s-ch">
The template uses [[Module:ReportTOC]] to render chapters dynamically.
<div class="rtoc-section-title">Chapters</div>
</noinclude>{{#invoke:ReportTOC|main}}<noinclude>
{{#if:{{{ch1title|}}}|<div class="rtoc-entry"><div class="rtoc-entry-text"><span class="rtoc-entry-title">{{{ch1title}}}</span>{{#if:{{{ch1subtitle|}}}|<span class="rtoc-entry-subtitle">{{{ch1subtitle}}}</span>}}</div><span class="rtoc-read">[[{{{ch1url}}}|Read]]</span></div>}}
{{#if:{{{ch2title|}}}|<div class="rtoc-entry"><div class="rtoc-entry-text"><span class="rtoc-entry-title">{{{ch2title}}}</span>{{#if:{{{ch2subtitle|}}}|<span class="rtoc-entry-subtitle">{{{ch2subtitle}}}</span>}}</div><span class="rtoc-read">[[{{{ch2url}}}|Read]]</span></div>}}
{{#if:{{{ch3title|}}}|<div class="rtoc-entry"><div class="rtoc-entry-text"><span class="rtoc-entry-title">{{{ch3title}}}</span>{{#if:{{{ch3subtitle|}}}|<span class="rtoc-entry-subtitle">{{{ch3subtitle}}}</span>}}</div><span class="rtoc-read">[[{{{ch3url}}}|Read]]</span></div>}}
{{#if:{{{ch4title|}}}|<div class="rtoc-entry"><div class="rtoc-entry-text"><span class="rtoc-entry-title">{{{ch4title}}}</span>{{#if:{{{ch4subtitle|}}}|<span class="rtoc-entry-subtitle">{{{ch4subtitle}}}</span>}}</div><span class="rtoc-read">[[{{{ch4url}}}|Read]]</span></div>}}
{{#if:{{{ch5title|}}}|<div class="rtoc-entry"><div class="rtoc-entry-text"><span class="rtoc-entry-title">{{{ch5title}}}</span>{{#if:{{{ch5subtitle|}}}|<span class="rtoc-entry-subtitle">{{{ch5subtitle}}}</span>}}</div><span class="rtoc-read">[[{{{ch5url}}}|Read]]</span></div>}}
{{#if:{{{ch6title|}}}|<div class="rtoc-entry"><div class="rtoc-entry-text"><span class="rtoc-entry-title">{{{ch6title}}}</span>{{#if:{{{ch6subtitle|}}}|<span class="rtoc-entry-subtitle">{{{ch6subtitle}}}</span>}}</div><span class="rtoc-read">[[{{{ch6url}}}|Read]]</span></div>}}
{{#if:{{{ch7title|}}}|<div class="rtoc-entry"><div class="rtoc-entry-text"><span class="rtoc-entry-title">{{{ch7title}}}</span>{{#if:{{{ch7subtitle|}}}|<span class="rtoc-entry-subtitle">{{{ch7subtitle}}}</span>}}</div><span class="rtoc-read">[[{{{ch7url}}}|Read]]</span></div>}}
{{#if:{{{ch8title|}}}|<div class="rtoc-entry"><div class="rtoc-entry-text"><span class="rtoc-entry-title">{{{ch8title}}}</span>{{#if:{{{ch8subtitle|}}}|<span class="rtoc-entry-subtitle">{{{ch8subtitle}}}</span>}}</div><span class="rtoc-read">[[{{{ch8url}}}|Read]]</span></div>}}
{{#if:{{{ch9title|}}}|<div class="rtoc-entry"><div class="rtoc-entry-text"><span class="rtoc-entry-title">{{{ch9title}}}</span>{{#if:{{{ch9subtitle|}}}|<span class="rtoc-entry-subtitle">{{{ch9subtitle}}}</span>}}</div><span class="rtoc-read">[[{{{ch9url}}}|Read]]</span></div>}}
{{#if:{{{ch10title|}}}|<div class="rtoc-entry"><div class="rtoc-entry-text"><span class="rtoc-entry-title">{{{ch10title}}}</span>{{#if:{{{ch10subtitle|}}}|<span class="rtoc-entry-subtitle">{{{ch10subtitle}}}</span>}}</div><span class="rtoc-read">[[{{{ch10url}}}|Read]]</span></div>}}
{{#if:{{{ch11title|}}}|<div class="rtoc-entry"><div class="rtoc-entry-text"><span class="rtoc-entry-title">{{{ch11title}}}</span>{{#if:{{{ch11subtitle|}}}|<span class="rtoc-entry-subtitle">{{{ch11subtitle}}}</span>}}</div><span class="rtoc-read">[[{{{ch11url}}}|Read]]</span></div>}}
{{#if:{{{ch12title|}}}|<div class="rtoc-entry"><div class="rtoc-entry-text"><span class="rtoc-entry-title">{{{ch12title}}}</span>{{#if:{{{ch12subtitle|}}}|<span class="rtoc-entry-subtitle">{{{ch12subtitle}}}</span>}}</div><span class="rtoc-read">[[{{{ch12url}}}|Read]]</span></div>}}
{{#if:{{{ch13title|}}}|<div class="rtoc-entry"><div class="rtoc-entry-text"><span class="rtoc-entry-title">{{{ch13title}}}</span>{{#if:{{{ch13subtitle|}}}|<span class="rtoc-entry-subtitle">{{{ch13subtitle}}}</span>}}</div><span class="rtoc-read">[[{{{ch13url}}}|Read]]</span></div>}}
{{#if:{{{ch14title|}}}|<div class="rtoc-entry"><div class="rtoc-entry-text"><span class="rtoc-entry-title">{{{ch14title}}}</span>{{#if:{{{ch14subtitle|}}}|<span class="rtoc-entry-subtitle">{{{ch14subtitle}}}</span>}}</div><span class="rtoc-read">[[{{{ch14url}}}|Read]]</span></div>}}
{{#if:{{{ch15title|}}}|<div class="rtoc-entry"><div class="rtoc-entry-text"><span class="rtoc-entry-title">{{{ch15title}}}</span>{{#if:{{{ch15subtitle|}}}|<span class="rtoc-entry-subtitle">{{{ch15subtitle}}}</span>}}</div><span class="rtoc-read">[[{{{ch15url}}}|Read]]</span></div>}}
{{#if:{{{ch16title|}}}|<div class="rtoc-entry"><div class="rtoc-entry-text"><span class="rtoc-entry-title">{{{ch16title}}}</span>{{#if:{{{ch16subtitle|}}}|<span class="rtoc-entry-subtitle">{{{ch16subtitle}}}</span>}}</div><span class="rtoc-read">[[{{{ch16url}}}|Read]]</span></div>}}
{{#if:{{{ch17title|}}}|<div class="rtoc-entry"><div class="rtoc-entry-text"><span class="rtoc-entry-title">{{{ch17title}}}</span>{{#if:{{{ch17subtitle|}}}|<span class="rtoc-entry-subtitle">{{{ch17subtitle}}}</span>}}</div><span class="rtoc-read">[[{{{ch17url}}}|Read]]</span></div>}}
{{#if:{{{ch18title|}}}|<div class="rtoc-entry"><div class="rtoc-entry-text"><span class="rtoc-entry-title">{{{ch18title}}}</span>{{#if:{{{ch18subtitle|}}}|<span class="rtoc-entry-subtitle">{{{ch18subtitle}}}</span>}}</div><span class="rtoc-read">[[{{{ch18url}}}|Read]]</span></div>}}
{{#if:{{{ch19title|}}}|<div class="rtoc-entry"><div class="rtoc-entry-text"><span class="rtoc-entry-title">{{{ch19title}}}</span>{{#if:{{{ch19subtitle|}}}|<span class="rtoc-entry-subtitle">{{{ch19subtitle}}}</span>}}</div><span class="rtoc-read">[[{{{ch19url}}}|Read]]</span></div>}}
{{#if:{{{ch20title|}}}|<div class="rtoc-entry"><div class="rtoc-entry-text"><span class="rtoc-entry-title">{{{ch20title}}}</span>{{#if:{{{ch20subtitle|}}}|<span class="rtoc-entry-subtitle">{{{ch20subtitle}}}</span>}}</div><span class="rtoc-read">[[{{{ch20url}}}|Read]]</span></div>}}
{{#if:{{{ch21title|}}}|<div class="rtoc-entry"><div class="rtoc-entry-text"><span class="rtoc-entry-title">{{{ch21title}}}</span>{{#if:{{{ch21subtitle|}}}|<span class="rtoc-entry-subtitle">{{{ch21subtitle}}}</span>}}</div><span class="rtoc-read">[[{{{ch21url}}}|Read]]</span></div>}}
{{#if:{{{ch22title|}}}|<div class="rtoc-entry"><div class="rtoc-entry-text"><span class="rtoc-entry-title">{{{ch22title}}}</span>{{#if:{{{ch22subtitle|}}}|<span class="rtoc-entry-subtitle">{{{ch22subtitle}}}</span>}}</div><span class="rtoc-read">[[{{{ch22url}}}|Read]]</span></div>}}
{{#if:{{{ch23title|}}}|<div class="rtoc-entry"><div class="rtoc-entry-text"><span class="rtoc-entry-title">{{{ch23title}}}</span>{{#if:{{{ch23subtitle|}}}|<span class="rtoc-entry-subtitle">{{{ch23subtitle}}}</span>}}</div><span class="rtoc-read">[[{{{ch23url}}}|Read]]</span></div>}}
{{#if:{{{ch24title|}}}|<div class="rtoc-entry"><div class="rtoc-entry-text"><span class="rtoc-entry-title">{{{ch24title}}}</span>{{#if:{{{ch24subtitle|}}}|<span class="rtoc-entry-subtitle">{{{ch24subtitle}}}</span>}}</div><span class="rtoc-read">[[{{{ch24url}}}|Read]]</span></div>}}
{{#if:{{{ch25title|}}}|<div class="rtoc-entry"><div class="rtoc-entry-text"><span class="rtoc-entry-title">{{{ch25title}}}</span>{{#if:{{{ch25subtitle|}}}|<span class="rtoc-entry-subtitle">{{{ch25subtitle}}}</span>}}</div><span class="rtoc-read">[[{{{ch25url}}}|Read]]</span></div>}}
</div>


<div class="s-an">
<div class="rtoc-section-title">Annexes</div>
<div class="rtoc-oos">Content in this section is out of scope</div>
</div>
</div></onlyinclude>
<noinclude>
== Usage ==
== Usage ==
<pre>
<pre>

Revision as of 11:45, 20 May 2026

ReportTOC Template

This template creates a styled table of contents for reports with sections for SPM, Technical Summary, Chapters, and Annexes.

The template uses Module:ReportTOC to render chapters dynamically.

Contents
Front Matter
Content in this section is out of scope
Annexes
Content in this section is out of scope

Usage

{{ReportTOC
| spmtitle    = Summary for Policymakers
| spmsubtitle = Key findings and policy implications
| spmurl      = IPCC:AR6/SYR/SPM

| tstitle    = Technical Summary
| tssubtitle = Detailed scientific assessment
| tsurl      = IPCC:AR6/SYR/TS

| ch1title    = Chapter 1: Framing and Context
| ch1subtitle = Concepts, methods and approaches
| ch1url      = IPCC:AR6/SYR/Chapter-1
| ch2title    = Chapter 2: Observed Changes
| ch2subtitle = Surface temperature and sea level
| ch2url      = IPCC:AR6/SYR/Chapter-2
}}

SPM and TS take a single entry each. Chapters supports up to 25 entries. Subtitles are optional for all entries.