Template:PageTitle: Difference between revisions

From Step Mods | Change The Game
No edit summary
mNo edit summary
Line 9: Line 9:
| skyrim=Skyrim_flare.png
| skyrim=Skyrim_flare.png
| skyrimse=Skyrimse_flare.png
| skyrimse=Skyrimse_flare.png
| #default=Delta_c.png }}|105px|class={{{classList|}}}]]</div><div class="media-body align-self-center mt-1"><p class="pagetitle-title mb-0">{{{title}}}</p>{{#if:{{{subtitle|}}}|<p class="pagetitle-subtitle mt-n2 mb-1">{{{subtitle}}}</p>}}{{#if:{{{author|}}}|<p class="mb-0">''by: {{{author}}}''}} {{#if:{{{forumtid|}}}|&nbsp;{{!}}&nbsp;[https://stepmodifications.org/forum/topic/{{{forumtid}}}-- '''Forum Topic''']</p>|{{#if:{{{forumtid|}}}|<p class="mb-0">[https://stepmodifications.org/forum/topic/{{{forumtid}}}-- '''Forum Topic''']</p>}}}}</div></div>{{#if: {{{breadcrumb|}}} | <div class="container-fluid mt-n3 mb-3"><i class="fas fa-chevron-left pr-2"></i> [[{{NAMESPACEE}}:{{ROOTPAGENAMEE}}|{{{breadcrumbName|{{ROOTPAGENAME}}}}}]]</div> | }}</includeonly><noinclude>__NOTOC__[[Category:Formatting Templates]]
| #default=Delta_c.png }}|105px|class={{{classList|}}}]]</div><div class="media-body align-self-center mt-1"><p class="pagetitle-title mb-0">{{{title}}}</p>{{#if:{{{subtitle|}}}|<p class="pagetitle-subtitle mt-n2 mb-1">{{{subtitle}}}</p>}}{{#if:{{{author|}}}|<p class="mb-0">''by: {{{author}}}''}} {{#if:{{{forum|}}}|&nbsp;{{!}}&nbsp;[https://stepmodifications.org/forum/topic/{{{forum}}}-- '''Forum Topic''']</p>|{{#if:{{{forum|}}}|<p class="mb-0">[https://stepmodifications.org/forum/topic/{{{forum}}}-- '''Forum Topic''']</p>}}}}</div></div>{{#if: {{{breadcrumb|}}} | <div class="container-fluid mt-n3 mb-3"><i class="fas fa-chevron-left pr-2"></i> [[{{NAMESPACEE}}:{{ROOTPAGENAMEE}}|{{{breadcrumbName|{{ROOTPAGENAME}}}}}]]</div> | }}</includeonly><noinclude>__NOTOC__[[Category:Formatting Templates]]


==Purpose & Usage==
==Purpose & Usage==
Line 18: Line 18:
{{GallerySimple|id=1|width=105|img=File:Morrowind_flare.png}}{{GallerySimple|id=1|width=105|img=File:Nomanssky_flare.png}}{{GallerySimple|id=1|width=105|img=File:Oblivion_flare.png}}{{GallerySimple|id=1|width=105|img=File:Skyrim_flare.png}}{{GallerySimple|id=1|width=105|img=File:Skyrimse_flare.png}}
{{GallerySimple|id=1|width=105|img=File:Morrowind_flare.png}}{{GallerySimple|id=1|width=105|img=File:Nomanssky_flare.png}}{{GallerySimple|id=1|width=105|img=File:Oblivion_flare.png}}{{GallerySimple|id=1|width=105|img=File:Skyrim_flare.png}}{{GallerySimple|id=1|width=105|img=File:Skyrimse_flare.png}}
{{clear}}
{{clear}}
===Parameters:===
=== Required Parameters ===
==== Required ====
<span class="salmontx">'''title'''</span> - Sets the title
; {{fc|red|<nowiki>title=</nowiki>}}
: '''Values'''
: This is the text that displays for the title and is a required parameter.
:: Default: n/a, <code>title=''TitleHere''</code>
: '''How to use:''' <code>title=text</code>


==== Optional ====
=== Optional Parameters ===
; {{fc|green|<nowiki>logo=</nowiki>}}
<span class="salmontx">'''logo'''</span> - Displays a logo to the left of the content
: (optional) Displays a logo to the left of the content
: '''Values'''
: '''Notes:'''
:: Default: <code>logo=delta</code>
:* Logos are constrained to a minimum of '''105px''' in width. Images with H > W work best.
:* fo3
:* User should [[Special:Upload|upload logo images]] used in combination with this template to the wiki.
:* fo4
:* If this parameter is left out, then the Step delta logo will be displayed.
:* fnv
: '''How to use:''' <code>logo=<uploadedFileName> or <switch></code> (e.g. <code>logo=Delta_c.png</code> or <code>logo=fo3</code> )
:* nomanssky
:: Available switches:
:* skyrim
::* fo3
:* skyrimse
::* fo4
::* fnv
::* nomanssky
::* skyrim
::* skyrimse


; {{fc|green|<nowiki>classList=</nowiki>}}
<span class="salmontx">'''classlist'''</span> - Provide a list of predefined, Bootstrap-friently CSS classes separated by a blank space to affect display of the image.
: (optional) This is used to provide a list of classes that are applied to the image.
: '''Values'''
: '''Notes:'''
:: Default: n/a, <code>classlist=''class1 class2 p-3 rounded-circle ...''</code>
:* Will only work with classes that are pre-defined and those that work on images.
:* Multiple classes are separated by a blank space.
: '''How to use:''' <code>classList=p-3 rounded-circle</code>


; {{fc|green|<nowiki>subtitle=</nowiki>}}
<span class="salmontx">'''subtitle'''</span> - Sets a subtitle
: (optional) This is the text that displays for the subtitle.
: '''Values'''
: '''How to use:''' <code>subtitle=text</code>
:: Default: n/a, <code>subtitle=''SubtitleHere''</code>


; {{fc|green|<nowiki>author=</nowiki>}}
<span class="salmontx">'''author'''</span> - Sets a subtitle
: (optional) field for the author(s)
: '''Values'''
: '''How to use:''' <code>author=text</code>
:: Default: n/a, <code>author=''Author(s)Here''</code>


; {{fc|green|<nowiki>forumtid=</nowiki>}}
<span class="salmontx">'''forum'''</span> - Sets a forum link if a support forum exists for the page. The <uniqueForumID> is found in the forum topic's URL:<br>{{Fc|highlight|<nowiki>https://stepmodifications.org/forum/topic/</nowiki>{{fc|yellow|'''14917'''}}<nowiki>-system-setup-guide/</nowiki>}}
: (optional) use a ''forum topic's ID'' to include a link to related forum topic
: '''Values'''
: '''Notes:
:: Default: n/a, <code>forum=''14917''</code>
:* The <uniqueForumID> is found in the forum topic's URL:<br>{{Fc|highlight|<nowiki>https://stepmodifications.org/forum/topic/</nowiki>{{fc|yellow|'''14917'''}}<nowiki>-system-setup-guide/</nowiki>}}
 
: '''How to use:''' <code>forumtid=<uniqueForumID></code> (e.g. <code>forumtid=14917</code> )
==Examples==
===Default Call===
The simplest call returns defaults for the template.
: '''Code:''' <code><nowiki>{{PageTitle|title=Title Here}}</nowiki></code>
: '''Result:'''
:: {{PageTitle|title=Title Here}}
<hr>
<hr>


==Usage Examples==
===Example 01 (all options w/default logo)===
===Example 01 (all options w/default logo)===
: '''Code:'''
: '''Code:'''
Line 67: Line 64:
: '''Result:'''
: '''Result:'''
:: {{PageTitle|logo=delta|title=Your Title Here|subtitle=Your subtitle text here|author= Team XYZ|forumtid=423}}
:: {{PageTitle|logo=delta|title=Your Title Here|subtitle=Your subtitle text here|author= Team XYZ|forumtid=423}}
<br>
<hr>
<hr>
<br>
<hr>


===Example 02 (using switches)===
===Example 02 (using switches)===
Line 78: Line 74:
:: {{PageTitle|logo=fo3|title=Your Title Here|subtitle=Your subtitle text here|author= Team XYZ|forumtid=423}}
:: {{PageTitle|logo=fo3|title=Your Title Here|subtitle=Your subtitle text here|author= Team XYZ|forumtid=423}}
:: {{PageTitle|logo=nomanssky|title=Your Title Here|subtitle=Your subtitle text here|author= Team XYZ|forumtid=423}}
:: {{PageTitle|logo=nomanssky|title=Your Title Here|subtitle=Your subtitle text here|author= Team XYZ|forumtid=423}}
<br>
<hr>
<hr>
<br>
<hr>


===Example 03 ===
===Example 03 ===
Line 88: Line 83:
: '''Result:'''
: '''Result:'''
:: {{PageTitle|logo=delta|title=Your Title Here|author= Team XYZ|forumtid=423}}
:: {{PageTitle|logo=delta|title=Your Title Here|author= Team XYZ|forumtid=423}}
==== Title Only ====
: '''Code:'''
:: <code><nowiki>{{PageTitle|title=Your Title Here}}</nowiki></code><br>
: '''Result:'''
:: {{PageTitle|title=Your Title Here}}
<br>
</noinclude>
</noinclude>

Revision as of 14:10, August 2, 2021


Purpose & Usage

Used at top of pages to include a standardized page-title header. This template relies upon global CSS classes.

Info-Logo.png

NOTE

EDITORS: This template will allow any image uploaded to the wiki. PM an administrator to add an image to this template if it does not exist. The format for image icons is 105+ px X 105+ px. This template also includes the __NOTITLE__ behavior switch by default; therefore, it's not necessary to include it on the page when the PageTitle template is used.

Available images

Required Parameters

title - Sets the title

Values
Default: n/a, title=TitleHere

Optional Parameters

logo - Displays a logo to the left of the content

Values
Default: logo=delta
  • fo3
  • fo4
  • fnv
  • nomanssky
  • skyrim
  • skyrimse

classlist - Provide a list of predefined, Bootstrap-friently CSS classes separated by a blank space to affect display of the image.

Values
Default: n/a, classlist=class1 class2 p-3 rounded-circle ...

subtitle - Sets a subtitle

Values
Default: n/a, subtitle=SubtitleHere

author - Sets a subtitle

Values
Default: n/a, author=Author(s)Here

forum - Sets a forum link if a support forum exists for the page. The <uniqueForumID> is found in the forum topic's URL:
https://stepmodifications.org/forum/topic/14917-system-setup-guide/

Values
Default: n/a, forum=14917

Examples

Default Call

The simplest call returns defaults for the template.

Code: {{PageTitle|title=Title Here}}
Result:
Delta c.png

Title Here



Example 01 (all options w/default logo)

Code:
{{PageTitle|logo=delta|title=Your Title Here|subtitle=Your subtitle text here|author= Team XYZ|forumtid=423}}
Result:
Delta c.png

Your Title Here

Your subtitle text here

by: Team XYZ



Example 02 (using switches)

Code:
{{PageTitle|logo=fo3|title=Your Title Here|subtitle=Your subtitle text here|author= Team XYZ|forumtid=423}}
{{PageTitle|logo=nomanssky|title=Your Title Here|subtitle=Your subtitle text here|author= Team XYZ|forumtid=423}}
Result:
Fo3 flare.png

Your Title Here

Your subtitle text here

by: Team XYZ

Nomanssky flare.png

Your Title Here

Your subtitle text here

by: Team XYZ



Example 03

No Subtitle

Code:
{{PageTitle|logo=delta|title=Your Title Here|author= Team XYZ|forumtid=423}}
Result:
Delta c.png

Your Title Here

by: Team XYZ