Template:NewsItem: Difference between revisions
Template page
More actions
Eloise Zomia (talk | contribs) No edit summary |
Eloise Zomia (talk | contribs) No edit summary |
||
| Line 1: | Line 1: | ||
<includeonly>__NOTOC__ __NOEDITSECTION__ | <includeonly>__NOTOC__ __NOEDITSECTION__ | ||
<div style="display:none;"> | <div style="display:none;"> | ||
[[Has event date::{{{date|}}}]] | [[Has event date::{{{date|}}}]] | ||
| Line 15: | Line 16: | ||
<div id="{{{date|}}}" class="news-card news-card--{{lc:{{{category|policy}}}}} {{#ifeq:{{{summary|}}}||news-card--compact|}} {{#ifeq:{{{links|}}}||news-card--compact|}}"> | <div id="{{{date|}}}" class="news-card news-card--{{lc:{{{category|policy}}}}} {{#ifeq:{{{summary|}}}||news-card--compact|}} {{#ifeq:{{{links|}}}||news-card--compact|}}"> | ||
<div class="news-card__header"> | <div class="news-card__header"> | ||
<div class="news-card__date">{{#time:j F Y|{{{date}}}}}</div> | <div class="news-card__date">{{#time:j F Y|{{{date}}}}}</div> | ||
| Line 41: | Line 43: | ||
</div> | </div> | ||
</includeonly> | </includeonly> | ||
<noinclude> | |||
== Usage == | |||
This template is used by SMW query output on [[Portal:Current Events]]. | |||
=== Minimal example === | |||
<pre> | |||
{{NewsItem | |||
|date=2026-01-16 | |||
|category=Policy | |||
|title=Example headline | |||
|summary=2–4 factual sentences. | |||
|source=https://example.com | |||
}} | |||
</pre> | |||
=== Optional fields === | |||
* <code>page</code> (link the headline to another wiki page) | |||
* <code>parent_story</code> (headline links to the parent story page) | |||
* <code>region_label</code> (small region label above title) | |||
* <code>links</code> (footer links block) | |||
* <code>status</code> (defaults to Single-day) | |||
* <code>gene_pool</code>, <code>growing_region</code>, <code>growing_area</code>, <code>appellation</code> | |||
</noinclude> | |||
Revision as of 08:23, 16 January 2026
Usage
This template is used by SMW query output on Portal:Current Events.
Minimal example
{{NewsItem
|date=2026-01-16
|category=Policy
|title=Example headline
|summary=2–4 factual sentences.
|source=https://example.com
}}
Optional fields
page(link the headline to another wiki page)parent_story(headline links to the parent story page)region_label(small region label above title)links(footer links block)status(defaults to Single-day)gene_pool,growing_region,growing_area,appellation