Difference between revisions of "User:Nemo/sandbox/templateannounce"

From Geohashing
imported>Nemo
(.)
imported>Nemo
m
 
(19 intermediate revisions by the same user not shown)
Line 1: Line 1:
 
<includeonly><div style='font-size:90%; margin:2px 10% 2px; padding: 2px;
 
<includeonly><div style='font-size:90%; margin:2px 10% 2px; padding: 2px;
{{#switch:{{{1}}}
+
{{#switch:{{{2|{{{bg}}}}}}
| red= border: 1px solid #f66; background: #fdd;'>
+
| black= border: 1px solid #000; background: #eee;
| orange= border: 1px solid #d90; background: #fda'>
+
| blue= border: 1px solid #99f; background: #ddf;
| yellow= border: 1px solid #dd0; background: #ffc'>
+
| green= border: 1px solid #3c3; background: #dfd;
| green= border: 1px solid #9d9; background: #dfd'>
+
| yellow= border: 1px solid #cc0; background: #ffc;
| blue= border: 1px solid #99f; background: #ddf'>
+
| orange= border: 1px solid #d90; background: #fda;
| border: 1px solid black; background: #ddd'>
+
| border: 1px solid #f66; background: #fdd;
}} {{{2}}} </div></includeonly><noinclude>
+
}} '> {{{1|{{{text}}}}}} </div></includeonly><noinclude>
A template for announcements of different colours...</noinclude>
+
A template for announcements of different colours...
 +
 
 +
 
 +
== Usage ==
 +
<nowiki>{{announce|This is a critical alert!|bg=colour}}</nowiki>
 +
* For use in alerting people to something critically important.
 +
* The '''bg''' colour may be 'red/orange/yellow/green/blue/black, or may be omitted in which case it defaults to red.
 +
 
 +
== Examples ==
 +
<nowiki>{{User:Nemo/sandbox/templateannounce|this is a '''black''' announcement|bg=black}}</nowiki>
 +
{{User:Nemo/sandbox/templateannounce|this is a '''black''' announcement|bg=black}}
 +
<nowiki>{{User:Nemo/sandbox/templateannounce|this is a '''blue''' announcement|bg=blue}}</nowiki>
 +
{{User:Nemo/sandbox/templateannounce|this is a '''blue''' announcement|bg=blue}}
 +
etc...
 +
{{User:Nemo/sandbox/templateannounce|this is a '''green''' announcement|bg=green}}
 +
{{User:Nemo/sandbox/templateannounce|this is a '''yellow''' announcement|bg=yellow}}
 +
{{User:Nemo/sandbox/templateannounce|this is a '''orange''' announcement|bg=orange}}
 +
{{User:Nemo/sandbox/templateannounce|this is a '''red''' announcement|bg=red}}
 +
<nowiki>{{User:Nemo/sandbox/templateannounce|this is a default announcement}}</nowiki>
 +
{{User:Nemo/sandbox/templateannounce|this is a default announcement}}
 +
 
 +
<!-- To future editors... I believe this templace can be extended to use param4|fg for text colour, and 5|align for alignment. However, it should default to the original (June2008) style - fill width centered red.
 +
 
 +
Alignment for [[Template:Expedition Images]] and [[Implementations]] pages which also have announce-like colour blocks. Note that this should all be in discussion ;)
 +
 
 +
Why am I not doing the rest?
 +
[a] apathy
 +
[b] not convinced it SHOULD be done
 +
[c] PROFIT! (no, doesn't really work does it?) :)
 +
 
 +
--Nemo
 +
 
 +
-->
 +
</noinclude>

Latest revision as of 11:34, 5 July 2008

A template for announcements of different colours...


Usage

{{announce|This is a critical alert!|bg=colour}}
  • For use in alerting people to something critically important.
  • The bg colour may be 'red/orange/yellow/green/blue/black, or may be omitted in which case it defaults to red.

Examples

{{User:Nemo/sandbox/templateannounce|this is a '''black''' announcement|bg=black}}
this is a black announcement
{{User:Nemo/sandbox/templateannounce|this is a '''blue''' announcement|bg=blue}}
this is a blue announcement

etc...

this is a green announcement
this is a yellow announcement
this is a orange announcement
this is a red announcement
{{User:Nemo/sandbox/templateannounce|this is a default announcement}}
this is a default announcement