Template:Fc: Difference between revisions

From Step Mods | Change The Game
mNo edit summary
mNo edit summary
Line 1: Line 1:
<includeonly><span class="{{#switch:{{lc:{{{1|}}}}}
<includeonly><span class="{{#switch:{{lc:{{{1|}}}}}
| red | warning = redtx
| salmon | instruction | heading = salmontx
| orange = orangetx
| yellow | issue = yellowtx
| chartr | bug = chartrtx
| green = greentx
| blue | notice = bluetx
| purple | dev = purpletx
| magenta = magenttx
| magenta = magenttx
| purple = purpletx
| highlight | brighter = hltx
| addition | enhancement | confirmation | blue = bluetx
| dimmer | dim = dimtx
| added | fix | functional | relevant | green = greentx
| #default = }}">{{{text|{{{2|}}}}}}</span></includeonly><noinclude>__NOTOC__ [[Category:Formatting Templates]]
| chartr = chartrtx
 
| issue | unknown | yellow = yellowtx
| instruction | ilheading | salmon | notice = salmontx
| change | merged | modification | updated | orange = orangetx
| dropped | removal | replaced | non-functional | warning | irrelevant | red = redtx
| important | highlight = hltx
| dimmer = dimtx
| #default = }}">{{{2}}}</span></includeonly><noinclude>__NOTOC__ [[Category:Formatting Templates]]
==Purpose & Usage==
==Purpose & Usage==
This template is used to change text color in accordance with the [[Project:SiteColorPallet|site color pallet]]. Deviation from this template using inline styling or other means is not recommended.
This template is used to change text color in accordance with the [[Project:SiteColorPallet|site color pallet]]. Deviation from this template using inline styling or other means is not recommended.


===Parameters:===
===Parameters:===
: '''Template:''' <code><nowiki>{{Fc|keyword|text=}}</nowiki></code>
: '''Template:''' <code><nowiki>{{Fc|keyword|displayedText}}</nowiki></code>


; {{Fc|red|''<nowiki>keyword</nowiki>''}}
; {{Fc|red|''<nowiki>1 (color keyword)</nowiki>''}}
: This is the keyword used to control the color of the text. The available keywords are in the table below.
: This this the first ( {{{1}}} ) anonymous parameter. It accepts color keywords, which control the color of the text. The available keywords are in the table below.
: '''How to use:''' <code>notice</code>
: '''Default:''' ''blank'', which results in the inherited color displaying
: '''How to use:''' <code><nowiki>{{Fc|notice|displayedText}}</nowiki></code>


; {{Fc|red|''<nowiki>text</nowiki>''}}
; {{Fc|red|''<nowiki>2 / text</nowiki>''}}
: This is the text that displays.
: This is the second ( {{{2}}} ) anonymous parameter. It is the text that displays.
: '''How to use:''' <code>text=BlahBlahBlah</code>
: '''Default:''' ''blank'', which results in no text being displayed.
: '''How to use:''' <code><nowiki>{{Fc|notice|BlahBlahBlah}}</nowiki></code>
:
:: By default, there is no need to name this parameter, however, there is a bug that exists when parsing the template that include "=" characters within this parameter. Essentially, the first instance of this character will break the template. To fix this, the second anonymous parameter is nested within a named parameter. Therefore, any time a "=" character has to be included within the displayed text, users will have to call the named parameter, {{Fc|red|'''''<nowiki>text</nowiki>'''''}}.
:: '''How to use:''' <code><nowiki>{{Fc|notice|text=BlahBlahBlah=3}}</nowiki></code>


=== Color Table ===
=== Color Table ===
Only the colors listed below are available for use. The reason the colors are restricted is because the Wiki supports themes; thus, the available colors have been carefully selected to work with all available themes.
Only the colors listed below are available for use. The reason the colors are restricted is that the Wiki supports themes; thus, the available colors have been carefully selected to work with all available themes.


The following keywords will produce their respective colors. At least one keyword is provided beyond the "color" keyword. These additional keywords help to specify the situations in which their respective colors are used. Bad keywords will result in no effect, thus, the ''parent'' text color will display.
The following is a table of the colors supported by the Step Wiki. See the [[Project:SiteColorPallet|Site Color Pallet]] for more in-depth information regarding the use of colors, including their Hex and CSS values, which will be useful for any custom development on user pages, theming, etc. The keywords are required for the template and will produce their respective colors, thus, have been included below with some usage information to guide users. Bad keywords will result in no effect, thus, the ''inherited'' text color from the ''parent'' will display.


{| class="wikitable"
{| class="wikitable mb-5"
|-
|-
! Key Words
! class="text-left" | Keywords
! class="text-left" | Usage
|-
|-
| {{Template:Fc|red|removal, non-functional, irrelevant, warning, red}}   
| {{Template:Fc|red|red, warning}}   
| Warning text without an "Alert" template, dropped mods, required elements, etc.
|-
|-
| {{Template:Fc|salmon|instruction, ilheading{{Template:Fc|highlight|<sup>1</sup>}}, salmon, notice}}
| {{Template:Fc|salmon|salmon, instruction, heading}}
| Emphasis within instruction sets, alterative color for headings, etc.
|-
|-
| {{Template:Fc|orange|change, modification, orange}}
| {{Template:Fc|orange|orange}}
| Call attention to changes such as updates or file moves, etc.
|-
|-
| {{Template:Fc|yellow|issue, unknown, yellow}}
| {{Template:Fc|yellow|yellow, issue}}
| Call attention to issues, etc.
|-
|-
| {{Template:Fc|chartr|chartr}}
| {{Template:Fc|chartr|chartr, bug}}
| Call out bugs, etc.
|-
|-
| {{Template:Fc|green|fix, functional, relevant, green}}
| {{Template:Fc|green|green}}
| Call attention to additions, etc.
|-
|-
| {{Template:Fc|blue|addition, enhancement, confirmation, blue}}
| {{Template:Fc|blue|blue, notice}}
| Notice text without an "Alert" template, etc.<br>{{fc|warning|''Try not to use this color for {{fc|notice|short phases}} as it can resemble {{fc|notice|links}}.''}}
|-
|-
| {{Template:Fc|purple|purple}}
| {{Template:Fc|purple|purple, dev}}
| Call out development, etc.
|-
|-
| {{Template:Fc|magenta|magenta}}
| {{Template:Fc|magenta|magenta}}
| Unknown, but it was requested by users.
|-
|-
| {{Template:Fc|highlight|important, highlight}}
| {{Template:Fc|highlight|highlight, brighter}}
|-
| Emphasis within normal text or additional emphasis within instruction sets, etc.
| {{Template:Fc|dimmer|dimmer}}
|-
|-
| colspan="2" | {{Template:Fc|highlight|<sup>1</sup>}}{{Fs|.8em|Only use this for "inline headings," which begin a paragraph instead of being on their own line.}}
| {{Template:Fc|dimmer|dimmer, dim}}
| Sub/Sup text, etc.
|}
|}


==Examples==
== Examples ==
'''Code:'''
'''Code:'''
<pre>{{Fc|instruction|The {{Fc|important|important part}} of an instruction is highlighted.}}</pre>
<pre>{{fc|instruction|The {{Fc|highlight|important part}} of an instruction is highlighted.}}</pre>
'''Result:'''
'''Result:''' {{fc|instruction|The {{Fc|highlight|important part}} of an instruction is highlighted.}}
{{Fc|instruction|The {{Fc|important|important part}} of an instruction is highlighted.}}


<hr class="my-5">
<hr class="my-5">


'''Code:'''
'''Code:'''
<pre>{{Fc|nonsense|Bad key words}} don't affect text color.</pre>
<pre>{{fc|highlight|text=Use the ''text'' parameter when "=" characters are used.}}</pre>
'''Result:'''
'''Result:''' {{fc|highlight|text=Use the ''text'' parameter when "=" characters are used.}}
{{Fc|nonsense|Bad key words}} don't affect text color.
 
<hr class="my-5">
 
'''Code:'''
<pre>{{fc|nonsense|Bad key words}} don't affect text color.</pre>
'''Result:''' {{fc|nonsense|Bad key words}} don't affect text color.


== See Also ==
== See Also ==
[[:Template:Fs]]
[[:Template:Fs]]<br>
[[Project:SiteColorPallet]]
[[Project:SiteColorPallet|Site Color Pallet]]
 
</noinclude>
</noinclude>

Revision as of 18:33, July 3, 2021


Purpose & Usage[edit source]

This template is used to change text color in accordance with the site color pallet. Deviation from this template using inline styling or other means is not recommended.

Parameters:[edit source]

Template: {{Fc|keyword|displayedText}}
1 (color keyword)
This this the first ( {{{1}}} ) anonymous parameter. It accepts color keywords, which control the color of the text. The available keywords are in the table below.
Default: blank, which results in the inherited color displaying
How to use: {{Fc|notice|displayedText}}
2 / text
This is the second ( {{{2}}} ) anonymous parameter. It is the text that displays.
Default: blank, which results in no text being displayed.
How to use: {{Fc|notice|BlahBlahBlah}}
By default, there is no need to name this parameter, however, there is a bug that exists when parsing the template that include "=" characters within this parameter. Essentially, the first instance of this character will break the template. To fix this, the second anonymous parameter is nested within a named parameter. Therefore, any time a "=" character has to be included within the displayed text, users will have to call the named parameter, text.
How to use: {{Fc|notice|text=BlahBlahBlah=3}}

Color Table[edit source]

Only the colors listed below are available for use. The reason the colors are restricted is that the Wiki supports themes; thus, the available colors have been carefully selected to work with all available themes.

The following is a table of the colors supported by the Step Wiki. See the Site Color Pallet for more in-depth information regarding the use of colors, including their Hex and CSS values, which will be useful for any custom development on user pages, theming, etc. The keywords are required for the template and will produce their respective colors, thus, have been included below with some usage information to guide users. Bad keywords will result in no effect, thus, the inherited text color from the parent will display.

Keywords Usage
red, warning Warning text without an "Alert" template, dropped mods, required elements, etc.
salmon, instruction, heading Emphasis within instruction sets, alterative color for headings, etc.
orange Call attention to changes such as updates or file moves, etc.
yellow, issue Call attention to issues, etc.
chartr, bug Call out bugs, etc.
green Call attention to additions, etc.
blue, notice Notice text without an "Alert" template, etc.
Try not to use this color for short phases as it can resemble links.
purple, dev Call out development, etc.
magenta Unknown, but it was requested by users.
highlight, brighter Emphasis within normal text or additional emphasis within instruction sets, etc.
dimmer, dim Sub/Sup text, etc.

Examples[edit source]

Code:

{{fc|instruction|The {{Fc|highlight|important part}} of an instruction is highlighted.}}

Result: The important part of an instruction is highlighted.


Code:

{{fc|highlight|text=Use the ''text'' parameter when "=" characters are used.}}

Result: Use the text parameter when "=" characters are used.


Code:

{{fc|nonsense|Bad key words}} don't affect text color.

Result: Bad key words don't affect text color.

See Also[edit source]

Template:Fs
Site Color Pallet