Template:News Timeline/doc: Difference between revisions

From aquila
Jump to navigation Jump to search
Created page with "<!-- Template:News Timeline/doc (transcluded into Global News, Domestic News and Character News) --> This is the shared documentation and TemplateData for the three news timeline templates. Each one adds a single table to an Era Nova year page. They are powered by Module:Timeline. == How to use == Put the template on a year page and give it the <code>Year</code>. Then fill in <b>only the days that had news</b>. Each day is one box; write one event per line: <pre..."
 
mNo edit summary
Line 1: Line 1:
<!-- Template:News Timeline/doc (transcluded into Global News, Domestic News and Character News) -->
<includeonly><div class="aquila-feed-item"><div class="aquila-feed-title">[[{{{Page_Name}}}|{{#if:{{{Title|}}}|{{{Title}}}|{{#titleparts:{{{Page_Name}}}|1|-1}}}}]]</div><div class="aquila-feed-meta"><span class="aquila-feed-type">{{{Type|}}}</span> · <span class="aquila-feed-date" title="{{{RealDate|}}}">Era Nova, {{#invoke:Calendar|prettify|{{{Period|}}}}}, Year {{{YearNum|}}}</span></div></div></includeonly><noinclude>Row template used by [[Template:Character News List]]. Not meant to be used on its own.</noinclude>
This is the shared documentation and TemplateData for the three news timeline templates. Each one adds a single table to an Era Nova year page. They are powered by [[Module:Timeline]].
=== PAGE: Template:News Timeline/doc ===
This is the shared documentation and TemplateData for the three news timeline templates ([[Template:Global News]], [[Template:Domestic News]], [[Template:Character News]]). Each adds one table to an Era Nova year page. They are powered by [[Module:Timeline]] and [[Module:Calendar]].
   
   
== How to use ==
== How to use ==
Put the template on a year page and give it the <code>Year</code>. Then fill in <b>only the days that had news</b>. Each day is one box; write one event per line:
<pre>
<pre>
Event Title; Character/Nation Name; optional real-world date
{{Global News
| Year = 1
}}
</pre>
</pre>
   
   
{| class="wikitable"
That is all most year pages need: every post written with <code><nowiki>{{News Header}}</nowiki></code> appears here automatically, on the day its <code>RealDate</code> falls in, and days with nothing are merged into one row.
! What you want !! What to type
|-
=== Events that have no page of their own ===
| A normal event || <code>Event Title; Character Name</code>
For something staff-only (like "Era Nova Begins") fill in the day's box, one event per line:
|-
| Several events on one day || Put each on its own line in that day's box.
|-
| Several characters in one event || Separate them with commas: <code>Event Title; Character Name, Nation Name</code>
|-
| No character or nation || Leave it out: <code>Event Title</code>
|-
| A custom link or label || Write the link yourself: <code><nowiki>[[Page Name|Display Text]]; [[Character Name]]</nowiki></code>. If you link one name in the character box, link all of them.
|-
| A specific real-world date || Add it as a third part: <code>Event Title; Character Name; 2026-09-14</code>
|}
   
   
A plain name is turned into a link automatically. The real-world date is calculated from the year and the day; days with nothing in them are merged into one row.
<pre>
Post title; Character or nation; optional real-world date
</pre>
   
   
=== Example ===
<pre>
<pre>
== Global News ==
{{Global News
{{Global News
| Year = 1
| Year = 1
| Day1 = Event Title 1; Character Name
| Day1 = <span>Era Nova Begins</span>
| Day12 =
Event Title 2; Nation Name
Event Title 3; Character Name, Nation Name; 2026-08-07
}}
}}
</pre>
</pre>
   
   
=== The 14 days ===
A plain name becomes a link automatically; wrap it in <code><nowiki><span>...</span></nowiki></code> to keep plain text. If a typed line is for a post that also has a page, the typed line is dropped so nothing appears twice.
{| class="wikitable"
! Day !! In-universe date
== Notes ==
|-
* A post only appears if it uses <code><nowiki>{{News Header}}</nowiki></code> with a valid <code>RealDate</code>.
| 1 || Early January
* Year pages are cached: after a new post is saved, purge the year page to see it straight away.
|-
* <code>Auto=no</code> turns the automatic list off (handy for testing).
| 2 || January–February
|-
| 3 || February–March
|-
| 4 || March–April
|-
| 5 || April–May
|-
| 6 || May–June
|-
| 7 || June
|-
| 8 || June–July
|-
| 9 || July–August
|-
| 10 || August–September
|-
| 11 || September–October
|-
| 12 || October–November
|-
| 13 || November–December
|-
| 14 || Late December
|}
   
   
<templatedata>
<templatedata>
{
{
  "description": "Adds one news section (Global, Domestic or Character) to an Era Nova year page. Fill in only the days that had news; empty days are merged automatically.",
  "description": "Adds one news section (Global, Domestic or Character) to an Era Nova year page. Posts that use {{News Header}} are listed automatically; empty days are merged.",
  "params": {
  "params": {
   "Year": {
   "Year": {
   "label": "Lore year",
   "label": "Lore year",
   "description": "The Era Nova year as a whole number (1, 2, 3...). The real-world dates are worked out from this.",
   "description": "The Era Nova year as a whole number (1, 2, 3...).",
   "type": "number",
   "type": "number",
   "required": true,
   "required": true,
Line 84: Line 47:
   },
   },
   "Day1": {
   "Day1": {
   "label": "Day 1: Early January",
   "label": "Extra events, day 1: Early January",
   "description": "One event per line, written as: Event Title; Character/Nation Name; real-world date. Only the title is needed. The date is optional and replaces the automatic one.",
   "description": "Only for events that do NOT have their own page. Posts that use {{News Header}} appear automatically. One event per line: Post title; Character or nation; optional real-world date.",
   "type": "string",
   "type": "string",
   "example": "Event Title; Character Name"
   "example": "Era Nova Begins; High Council"
   },
   },
   "Day2": {
   "Day2": {
   "label": "Day 2: January–February",
   "label": "Extra events, day 2: January–February",
   "description": "One event per line, written as: Event Title; Character/Nation Name; real-world date. Only the title is needed. The date is optional and replaces the automatic one.",
   "description": "Only for events that do NOT have their own page. Posts that use {{News Header}} appear automatically. One event per line: Post title; Character or nation; optional real-world date.",
   "type": "string",
   "type": "string",
   "example": "Event Title; Character Name"
   "example": "Era Nova Begins; High Council"
   },
   },
   "Day3": {
   "Day3": {
   "label": "Day 3: February–March",
   "label": "Extra events, day 3: February–March",
   "description": "One event per line, written as: Event Title; Character/Nation Name; real-world date. Only the title is needed. The date is optional and replaces the automatic one.",
   "description": "Only for events that do NOT have their own page. Posts that use {{News Header}} appear automatically. One event per line: Post title; Character or nation; optional real-world date.",
   "type": "string",
   "type": "string",
   "example": "Event Title; Character Name"
   "example": "Era Nova Begins; High Council"
   },
   },
   "Day4": {
   "Day4": {
   "label": "Day 4: March–April",
   "label": "Extra events, day 4: March–April",
   "description": "One event per line, written as: Event Title; Character/Nation Name; real-world date. Only the title is needed. The date is optional and replaces the automatic one.",
   "description": "Only for events that do NOT have their own page. Posts that use {{News Header}} appear automatically. One event per line: Post title; Character or nation; optional real-world date.",
   "type": "string",
   "type": "string",
   "example": "Event Title; Character Name"
   "example": "Era Nova Begins; High Council"
   },
   },
   "Day5": {
   "Day5": {
   "label": "Day 5: April–May",
   "label": "Extra events, day 5: April–May",
   "description": "One event per line, written as: Event Title; Character/Nation Name; real-world date. Only the title is needed. The date is optional and replaces the automatic one.",
   "description": "Only for events that do NOT have their own page. Posts that use {{News Header}} appear automatically. One event per line: Post title; Character or nation; optional real-world date.",
   "type": "string",
   "type": "string",
   "example": "Event Title; Character Name"
   "example": "Era Nova Begins; High Council"
   },
   },
   "Day6": {
   "Day6": {
   "label": "Day 6: May–June",
   "label": "Extra events, day 6: May–June",
   "description": "One event per line, written as: Event Title; Character/Nation Name; real-world date. Only the title is needed. The date is optional and replaces the automatic one.",
   "description": "Only for events that do NOT have their own page. Posts that use {{News Header}} appear automatically. One event per line: Post title; Character or nation; optional real-world date.",
   "type": "string",
   "type": "string",
   "example": "Event Title; Character Name"
   "example": "Era Nova Begins; High Council"
   },
   },
   "Day7": {
   "Day7": {
   "label": "Day 7: June",
   "label": "Extra events, day 7: June",
   "description": "One event per line, written as: Event Title; Character/Nation Name; real-world date. Only the title is needed. The date is optional and replaces the automatic one.",
   "description": "Only for events that do NOT have their own page. Posts that use {{News Header}} appear automatically. One event per line: Post title; Character or nation; optional real-world date.",
   "type": "string",
   "type": "string",
   "example": "Event Title; Character Name"
   "example": "Era Nova Begins; High Council"
   },
   },
   "Day8": {
   "Day8": {
   "label": "Day 8: June–July",
   "label": "Extra events, day 8: June–July",
   "description": "One event per line, written as: Event Title; Character/Nation Name; real-world date. Only the title is needed. The date is optional and replaces the automatic one.",
   "description": "Only for events that do NOT have their own page. Posts that use {{News Header}} appear automatically. One event per line: Post title; Character or nation; optional real-world date.",
   "type": "string",
   "type": "string",
   "example": "Event Title; Character Name"
   "example": "Era Nova Begins; High Council"
   },
   },
   "Day9": {
   "Day9": {
   "label": "Day 9: July–August",
   "label": "Extra events, day 9: July–August",
   "description": "One event per line, written as: Event Title; Character/Nation Name; real-world date. Only the title is needed. The date is optional and replaces the automatic one.",
   "description": "Only for events that do NOT have their own page. Posts that use {{News Header}} appear automatically. One event per line: Post title; Character or nation; optional real-world date.",
   "type": "string",
   "type": "string",
   "example": "Event Title; Character Name"
   "example": "Era Nova Begins; High Council"
   },
   },
   "Day10": {
   "Day10": {
   "label": "Day 10: August–September",
   "label": "Extra events, day 10: August–September",
   "description": "One event per line, written as: Event Title; Character/Nation Name; real-world date. Only the title is needed. The date is optional and replaces the automatic one.",
   "description": "Only for events that do NOT have their own page. Posts that use {{News Header}} appear automatically. One event per line: Post title; Character or nation; optional real-world date.",
   "type": "string",
   "type": "string",
   "example": "Event Title; Character Name"
   "example": "Era Nova Begins; High Council"
   },
   },
   "Day11": {
   "Day11": {
   "label": "Day 11: September–October",
   "label": "Extra events, day 11: September–October",
   "description": "One event per line, written as: Event Title; Character/Nation Name; real-world date. Only the title is needed. The date is optional and replaces the automatic one.",
   "description": "Only for events that do NOT have their own page. Posts that use {{News Header}} appear automatically. One event per line: Post title; Character or nation; optional real-world date.",
   "type": "string",
   "type": "string",
   "example": "Event Title; Character Name"
   "example": "Era Nova Begins; High Council"
   },
   },
   "Day12": {
   "Day12": {
   "label": "Day 12: October–November",
   "label": "Extra events, day 12: October–November",
   "description": "One event per line, written as: Event Title; Character/Nation Name; real-world date. Only the title is needed. The date is optional and replaces the automatic one.",
   "description": "Only for events that do NOT have their own page. Posts that use {{News Header}} appear automatically. One event per line: Post title; Character or nation; optional real-world date.",
   "type": "string",
   "type": "string",
   "example": "Event Title; Character Name"
   "example": "Era Nova Begins; High Council"
   },
   },
   "Day13": {
   "Day13": {
   "label": "Day 13: November–December",
   "label": "Extra events, day 13: November–December",
   "description": "One event per line, written as: Event Title; Character/Nation Name; real-world date. Only the title is needed. The date is optional and replaces the automatic one.",
   "description": "Only for events that do NOT have their own page. Posts that use {{News Header}} appear automatically. One event per line: Post title; Character or nation; optional real-world date.",
   "type": "string",
   "type": "string",
   "example": "Event Title; Character Name"
   "example": "Era Nova Begins; High Council"
   },
   },
   "Day14": {
   "Day14": {
   "label": "Day 14: Late December",
   "label": "Extra events, day 14: Late December",
   "description": "One event per line, written as: Event Title; Character/Nation Name; real-world date. Only the title is needed. The date is optional and replaces the automatic one.",
   "description": "Only for events that do NOT have their own page. Posts that use {{News Header}} appear automatically. One event per line: Post title; Character or nation; optional real-world date.",
  "type": "string",
  "example": "Era Nova Begins; High Council"
  },
  "Auto": {
  "label": "Read posts automatically",
  "description": "Leave blank to list posts from the news database. Write 'no' to show only the lines typed here.",
   "type": "string",
   "type": "string",
   "example": "Event Title; Character Name"
   "required": false,
  "suggestedvalues": [
    "no"
  ]
   }
   }
  },
  },
Line 183: Line 155:
   "Day12",
   "Day12",
   "Day13",
   "Day13",
   "Day14"
   "Day14",
  "Auto"
  ]
  ]
}
}
</templatedata>
</templatedata>

Revision as of 09:43, 24 October 2026

Row template used by Template:Character News List. Not meant to be used on its own.


PAGE: Template:News Timeline/doc

This is the shared documentation and TemplateData for the three news timeline templates (Template:Global News, Template:Domestic News, Template:Character News). Each adds one table to an Era Nova year page. They are powered by Module:Timeline and Module:Calendar.

How to use

{{Global News
| Year = 1
}}

That is all most year pages need: every post written with {{News Header}} appears here automatically, on the day its RealDate falls in, and days with nothing are merged into one row.

Events that have no page of their own

For something staff-only (like "Era Nova Begins") fill in the day's box, one event per line:

Post title; Character or nation; optional real-world date
{{Global News
| Year = 1
| Day1 = <span>Era Nova Begins</span>
}}

A plain name becomes a link automatically; wrap it in <span>...</span> to keep plain text. If a typed line is for a post that also has a page, the typed line is dropped so nothing appears twice.

Notes

  • A post only appears if it uses {{News Header}} with a valid RealDate.
  • Year pages are cached: after a new post is saved, purge the year page to see it straight away.
  • Auto=no turns the automatic list off (handy for testing).

Adds one news section (Global, Domestic or Character) to an Era Nova year page. Posts that use {{News Header}} are listed automatically; empty days are merged.

Template parameters

ParameterDescriptionTypeStatus
Lore yearYear

The Era Nova year as a whole number (1, 2, 3...).

Example
1
Numberrequired
Extra events, day 1: Early JanuaryDay1

Only for events that do NOT have their own page. Posts that use {{News Header}} appear automatically. One event per line: Post title; Character or nation; optional real-world date.

Example
Era Nova Begins; High Council
Stringoptional
Extra events, day 2: January–FebruaryDay2

Only for events that do NOT have their own page. Posts that use {{News Header}} appear automatically. One event per line: Post title; Character or nation; optional real-world date.

Example
Era Nova Begins; High Council
Stringoptional
Extra events, day 3: February–MarchDay3

Only for events that do NOT have their own page. Posts that use {{News Header}} appear automatically. One event per line: Post title; Character or nation; optional real-world date.

Example
Era Nova Begins; High Council
Stringoptional
Extra events, day 4: March–AprilDay4

Only for events that do NOT have their own page. Posts that use {{News Header}} appear automatically. One event per line: Post title; Character or nation; optional real-world date.

Example
Era Nova Begins; High Council
Stringoptional
Extra events, day 5: April–MayDay5

Only for events that do NOT have their own page. Posts that use {{News Header}} appear automatically. One event per line: Post title; Character or nation; optional real-world date.

Example
Era Nova Begins; High Council
Stringoptional
Extra events, day 6: May–JuneDay6

Only for events that do NOT have their own page. Posts that use {{News Header}} appear automatically. One event per line: Post title; Character or nation; optional real-world date.

Example
Era Nova Begins; High Council
Stringoptional
Extra events, day 7: JuneDay7

Only for events that do NOT have their own page. Posts that use {{News Header}} appear automatically. One event per line: Post title; Character or nation; optional real-world date.

Example
Era Nova Begins; High Council
Stringoptional
Extra events, day 8: June–JulyDay8

Only for events that do NOT have their own page. Posts that use {{News Header}} appear automatically. One event per line: Post title; Character or nation; optional real-world date.

Example
Era Nova Begins; High Council
Stringoptional
Extra events, day 9: July–AugustDay9

Only for events that do NOT have their own page. Posts that use {{News Header}} appear automatically. One event per line: Post title; Character or nation; optional real-world date.

Example
Era Nova Begins; High Council
Stringoptional
Extra events, day 10: August–SeptemberDay10

Only for events that do NOT have their own page. Posts that use {{News Header}} appear automatically. One event per line: Post title; Character or nation; optional real-world date.

Example
Era Nova Begins; High Council
Stringoptional
Extra events, day 11: September–OctoberDay11

Only for events that do NOT have their own page. Posts that use {{News Header}} appear automatically. One event per line: Post title; Character or nation; optional real-world date.

Example
Era Nova Begins; High Council
Stringoptional
Extra events, day 12: October–NovemberDay12

Only for events that do NOT have their own page. Posts that use {{News Header}} appear automatically. One event per line: Post title; Character or nation; optional real-world date.

Example
Era Nova Begins; High Council
Stringoptional
Extra events, day 13: November–DecemberDay13

Only for events that do NOT have their own page. Posts that use {{News Header}} appear automatically. One event per line: Post title; Character or nation; optional real-world date.

Example
Era Nova Begins; High Council
Stringoptional
Extra events, day 14: Late DecemberDay14

Only for events that do NOT have their own page. Posts that use {{News Header}} appear automatically. One event per line: Post title; Character or nation; optional real-world date.

Example
Era Nova Begins; High Council
Stringoptional
Read posts automaticallyAuto

Leave blank to list posts from the news database. Write 'no' to show only the lines typed here.

Suggested values
no
Stringoptional