Template:YouTube link: Difference between revisions
Template page
More actions
m Build reusable tournament data and rendering system |
m Build reusable tournament data and rendering system |
||
| Line 1: | Line 1: | ||
<includeonly><templatestyles src="Template:YouTube link/styles.css" />{{#if:{{{id|{{{1|}}}}}}|<span class="loka-youtube-link">[https://www.youtube.com/watch?v={{{id|{{{1|}}}}}} "{{{label|{{PAGENAME}}}}}"] on [[File:YouTube icon.png|14px|link=|alt=YouTube]] YouTube{{#if:{{{credit|}}}|<span class="loka-youtube-link-credit"> (credit: {{{credit|}}})</span>}}</span>{{#ifeq:{{lc:{{{explicit|}}}}}|yes|<span class="loka-youtube-link-warning">Please note this video may contain strong language</span>}}}}</includeonly><noinclude> | <includeonly><templatestyles src="Template:YouTube link/styles.css" />{{#if:{{{id|{{{1|}}}}}}|<span class="loka-youtube-link">[https://www.youtube.com/watch?v={{{id|{{{1|}}}}}} "{{{label|{{PAGENAME}}}}}"] {{#if:{{{official|}}}|from [[File:Loka icon.png|14px|link=|alt=Loka]] Loka's [[File:YouTube icon.png|14px|link=|alt=YouTube]] YouTube|on [[File:YouTube icon.png|14px|link=|alt=YouTube]] YouTube{{#if:{{{credit|}}}|<span class="loka-youtube-link-credit"> (credit: {{{credit|}}})</span>}}}}</span>{{#ifeq:{{lc:{{{explicit|}}}}}|yes|<span class="loka-youtube-link-warning">Please note this video may contain strong language</span>}}}}</includeonly><noinclude> | ||
== Usage == | == Usage == | ||
| Line 7: | Line 7: | ||
Set <code>explicit=yes</code> to show the strong-language notice. <code>credit</code> is optional and, when given, shows who recorded/uploaded the video | Set <code>explicit=yes</code> to show the strong-language notice. <code>credit</code> is optional and, when given, shows who recorded/uploaded the video | ||
Set <code>official=yes</code> for a video uploaded by the official Loka Minecraft channel -- this shows "from [[File:Loka icon.png|14px|link=|alt=Loka]] Loka's [[File:YouTube icon.png|14px|link=|alt=YouTube]] YouTube" instead of a per-video credit, since the whole channel is already the attribution | |||
[[Category:External link templates]] | [[Category:External link templates]] | ||
</noinclude> | </noinclude> | ||
Revision as of 17:31, 19 August 2026
Usage
{{YouTube link|id=VIDEO_ID|label=Video title|credit=Recorder name}}
The first unnamed parameter can be used instead of id. The linked label defaults to the page name and is always shown in quotes
Set explicit=yes to show the strong-language notice. credit is optional and, when given, shows who recorded/uploaded the video
Set official=yes for a video uploaded by the official Loka Minecraft channel -- this shows "from
Loka's
YouTube" instead of a per-video credit, since the whole channel is already the attribution