Difference between revisions of "Template:Msgbox/doc"

From WikiCorporates
Jump to navigation Jump to search
(Created page with "{{Documentation subpage}} == Usage == I copied 3 of Wikipedia's message boxes from [https://en.wikipedia.org/wiki/Template:Cmbox here], and the styles from [https://en.wikiped...")
 
 
(4 intermediate revisions by the same user not shown)
Line 1: Line 1:
−
{{Documentation subpage}}
+
=== Usage ===
−
== Usage ==
 
 
I copied 3 of Wikipedia's message boxes from [https://en.wikipedia.org/wiki/Template:Cmbox here], and the styles from [https://en.wikipedia.org/wiki/MediaWiki:Common.css here]. Wikipedia uses these particular styles on Category pages, but I think they're cute enough to use on Article pages too. Wikipedia's messageboxes for Article pages are [https://en.wikipedia.org/wiki/Template:Ambox here].
 
I copied 3 of Wikipedia's message boxes from [https://en.wikipedia.org/wiki/Template:Cmbox here], and the styles from [https://en.wikipedia.org/wiki/MediaWiki:Common.css here]. Wikipedia uses these particular styles on Category pages, but I think they're cute enough to use on Article pages too. Wikipedia's messageboxes for Article pages are [https://en.wikipedia.org/wiki/Template:Ambox here].
  
Line 12: Line 11:
  
 
==== Example Message Usage ====
 
==== Example Message Usage ====
−
* Protection: This template is currently protected from editing.
+
{{Msgbox|type=protection|text=Protection: This template is currently protected from editing.}}
−
* Content: Major warnings eg. "PoV" and "Categorization of people disputed"
+
 
−
* Style: Minor warnings and problems such as "Underpopulated category"
+
{{Msgbox|type=content|text=Content: Major warnings eg. "PoV" and "Categorization of people disputed".}}
−
* Notice: Notices and messages of any kind, both permanent and temporary
+
 
 +
{{Msgbox|type=style|text=Style: Minor warnings and problems such as "Underpopulated category".}}
 +
 
 +
{{Msgbox|type=notice|text=Notice: Notices and messages of any kind, both permanent and temporary.}}
  
 
<pre>
 
<pre>
Line 28: Line 30:
 
td class="mbox-text": border:none; padding:0.25em0.9em; width:100%;
 
td class="mbox-text": border:none; padding:0.25em0.9em; width:100%;
 
</pre>
 
</pre>
−
<noinclude>[[Category:WikiPolitiks templates]]</noinclude>
+
 
 +
Nb: got the idea about how to use "switch" in the template from here: [http://templates.wikia.com/wiki/Template:Ambox_by_color Templates Wiki]
 +
<includeonly>[[Category:WikiCorporates templates]]</includeonly>

Latest revision as of 21:46, 30 May 2020

Usage

I copied 3 of Wikipedia's message boxes from here, and the styles from here. Wikipedia uses these particular styles on Category pages, but I think they're cute enough to use on Article pages too. Wikipedia's messageboxes for Article pages are here.

To use:

{{Msgbox
| type = protection | content | style | notice (default)
| text = This is a '''Container category'''. Due to its scope, it should contain ''only'' subcategories.
}}

Example Message Usage

File:Padlock-silver-medium.svg Protection: This template is currently protected from editing.
Ambox important.svg Content: Major warnings eg. "PoV" and "Categorization of people disputed".
File:Edit-clear.svg Style: Minor warnings and problems such as "Underpopulated category".
Information icon4.svg Notice: Notices and messages of any kind, both permanent and temporary.
Wikipedia's styles for these messageboxes:
table class="plainlinks cmbox cmbox-notice"
  cmbox: margin:3px 10%; border-collapse:collapse; border: 1px solid #a2a9b1; background:#dfe8ff;
  cmbox-protection: background:#efefe1;
  cmbox-content:    background:#ffe7ce; 
  cmbox-style:      background:#fff9db;
  cmbox-notice:     background:#d8e8ff;
td class="mbox-image": border:none; padding:2px 0 2px 0.9em; text-align:center;
td class="mbox-text": border:none; padding:0.25em0.9em; width:100%;

Nb: got the idea about how to use "switch" in the template from here: Templates Wiki