Difference between revisions of "Template:Textbox"

From MK8
Jump to navigation Jump to search
(Created page with "<includeonly><div class="textbox {{{1|}}}"> {{#if: {{{2}}} |<div class="textbox-head">{{{2}}}</div> }}<div class="textbox-body">{{{3}}}</div></div></includeonly><noinclude> _...")
 
 
(One intermediate revision by one other user not shown)
Line 1: Line 1:
<includeonly><div class="textbox {{{1|}}}">
+
<includeonly><div class="textbox {{{1|}}}"><!--
{{#if: {{{2}}} |<div class="textbox-head">{{{2}}}</div>
+
-->{{#if:{{{2|}}}|<div class=textbox-head>{{{2}}}</div>}}<!--
}}<div class="textbox-body">{{{3}}}</div></div></includeonly><noinclude>
+
-->{{#if:{{{3|}}}|<div class=textbox-body>{{{3}}}</div>}}<!--
 
+
--></div></includeonly><noinclude>
__TOC__
 
 
 
 
== Usage ==
 
== Usage ==
  
''textbox'' elements create CSS baset boxes and tables. The presentation is controlled by [[MediaWiki:Common.css]].
+
''textbox'' elements create CSS based boxes and tables. The presentation is controlled by [[MediaWiki:Common.css]].
 
         Usage: '''<nowiki>{{textbox|attributes|head_line|text}}</nowiki>'''
 
         Usage: '''<nowiki>{{textbox|attributes|head_line|text}}</nowiki>'''
 
  or in tables: '''class="textbox attributes"'''
 
  or in tables: '''class="textbox attributes"'''
Line 27: Line 25:
 
** '''huge''': Head line and text is enlarged by 40%.
 
** '''huge''': Head line and text is enlarged by 40%.
 
</li>
 
</li>
<li>'''head_line''': The head line of the textbox or table, always centerd.</li>
+
<li>'''head_line''': The head line of the textbox or table, always centered.</li>
 
<li>'''text''': free wiki text for textbox body.</li>
 
<li>'''text''': free wiki text for textbox body.</li>
 
</ul>
 
</ul>
 +
If '''head_line''' or '''text''' contains an equal sign (=), use <tt>'''<nowiki>{{=}}</nowiki>'''</tt> instead.
  
 
== Textbox Examples ==
 
== Textbox Examples ==
Line 37: Line 36:
 
=== Named schemas for special usage ===
 
=== Named schemas for special usage ===
  
This named schemes are preferred over the contrete colors.
+
This named schemes are preferred over the concrete colors.
  
 
{{textbox|news|Table 'news'|
 
{{textbox|news|Table 'news'|
Line 131: Line 130:
 
}}
 
}}
  
== Tabellen Examples ==
+
== Table Examples ==
  
 
The following examples show tables with alternating attribute.
 
The following examples show tables with alternating attribute.
The right tables use additionally ''flat-right'.
+
The right tables use additionally ''float-right'.
  
 
<div class="float-right">
 
<div class="float-right">

Latest revision as of 16:35, 2 May 2022

Usage

textbox elements create CSS based boxes and tables. The presentation is controlled by MediaWiki:Common.css.

       Usage: {{textbox|attributes|head_line|text}}
or in tables: class="textbox attributes"
  • attributes is one or more of the following keywords:
    • Color scheme:
      • news: news (=cyan)
    • Concrete colors: red, orange, yellow, green, cyan, blue, magenta, white, gray and black
    • Alignment:
      • center: centered text.
      • float-left: left floated textbox or table.
      • float-right: right floated textbox or table.
    • Options:
      • headline: The first line is a column header and will be set with a emphasized color.
      • grid: A colored grid (tables only).
      • alt: Alternating row colors (tables only).
      • large: Head line and text is enlarged by 20%.
      • huge: Head line and text is enlarged by 40%.
  • head_line: The head line of the textbox or table, always centered.
  • text: free wiki text for textbox body.

If head_line or text contains an equal sign (=), use {{=}} instead.

Textbox Examples

standard textbox
Textbox without attributes

Named schemas for special usage

This named schemes are preferred over the concrete colors.

Table 'news'

Attributes: news

A short sentence.

A longer message. The message is repeated several times. A longer message. The message is repeated several times. A longer message. The message is repeated several times.

Concrete Colors

Textbox examples with alternating attributes:

Table 'red'

Attributes: red

A short sentence.

A longer message. The message is repeated several times. A longer message. The message is repeated several times. A longer message. The message is repeated several times.

Table 'orange large'

Attributes: orange large

A short sentence.

A longer message. The message is repeated several times. A longer message. The message is repeated several times. A longer message. The message is repeated several times.

Table 'yellow huge'

Attributes: yellow huge

A short sentence.

A longer message. The message is repeated several times. A longer message. The message is repeated several times. A longer message. The message is repeated several times.

Table 'green center'

Attributes: green center

A short sentence.

A longer message. The message is repeated several times. A longer message. The message is repeated several times. A longer message. The message is repeated several times.

Table 'cyan'

Attributes: cyan

A short sentence.

A longer message. The message is repeated several times. A longer message. The message is repeated several times. A longer message. The message is repeated several times.

Table 'blue large'

Attributes: blue large

A short sentence.

A longer message. The message is repeated several times. A longer message. The message is repeated several times. A longer message. The message is repeated several times.

Table 'magenta huge'

Attributes: magenta huge

A short sentence.

A longer message. The message is repeated several times. A longer message. The message is repeated several times. A longer message. The message is repeated several times.

Table 'white center'

Attributes: white center

A short sentence.

A longer message. The message is repeated several times. A longer message. The message is repeated several times. A longer message. The message is repeated several times.

Table 'gray'

Attributes: gray

A short sentence.

A longer message. The message is repeated several times. A longer message. The message is repeated several times. A longer message. The message is repeated several times.

Table 'black large'

Attributes: black large

A short sentence.

A longer message. The message is repeated several times. A longer message. The message is repeated several times. A longer message. The message is repeated several times.

Table Examples

The following examples show tables with alternating attribute. The right tables use additionally float-right'.

Table 'red alt grid float-right'
Attributes: red alt grid float-right
Text 1: A short sentence.
Text 2: A longer message. The message is repeated several times. A longer message. The message is repeated several times.
Text 3: A longer message. The message is repeated several times. A longer message. The message is repeated several times. A longer message. The message is repeated several times.
Text 4: A short sentence.
Table 'orange alt float-right'
Attributes: orange alt float-right
Text 1: A short sentence.
Text 2: A longer message. The message is repeated several times. A longer message. The message is repeated several times.
Text 3: A longer message. The message is repeated several times. A longer message. The message is repeated several times. A longer message. The message is repeated several times.
Text 4: A short sentence.
Table 'yellow grid float-right'
Attributes: yellow grid float-right
Text 1: A short sentence.
Text 2: A longer message. The message is repeated several times. A longer message. The message is repeated several times.
Text 3: A longer message. The message is repeated several times. A longer message. The message is repeated several times. A longer message. The message is repeated several times.
Text 4: A short sentence.
Table 'green float-right'
Attributes: green float-right
Text 1: A short sentence.
Text 2: A longer message. The message is repeated several times. A longer message. The message is repeated several times.
Text 3: A longer message. The message is repeated several times. A longer message. The message is repeated several times. A longer message. The message is repeated several times.
Text 4: A short sentence.
Table 'cyan alt grid float-right'
Attributes: cyan alt grid float-right
Text 1: A short sentence.
Text 2: A longer message. The message is repeated several times. A longer message. The message is repeated several times.
Text 3: A longer message. The message is repeated several times. A longer message. The message is repeated several times. A longer message. The message is repeated several times.
Text 4: A short sentence.
Table 'blue alt float-right'
Attributes: blue alt float-right
Text 1: A short sentence.
Text 2: A longer message. The message is repeated several times. A longer message. The message is repeated several times.
Text 3: A longer message. The message is repeated several times. A longer message. The message is repeated several times. A longer message. The message is repeated several times.
Text 4: A short sentence.
Table 'magenta grid float-right'
Attributes: magenta grid float-right
Text 1: A short sentence.
Text 2: A longer message. The message is repeated several times. A longer message. The message is repeated several times.
Text 3: A longer message. The message is repeated several times. A longer message. The message is repeated several times. A longer message. The message is repeated several times.
Text 4: A short sentence.
Table 'white float-right'
Attributes: white float-right
Text 1: A short sentence.
Text 2: A longer message. The message is repeated several times. A longer message. The message is repeated several times.
Text 3: A longer message. The message is repeated several times. A longer message. The message is repeated several times. A longer message. The message is repeated several times.
Text 4: A short sentence.
Table 'gray alt grid float-right'
Attributes: gray alt grid float-right
Text 1: A short sentence.
Text 2: A longer message. The message is repeated several times. A longer message. The message is repeated several times.
Text 3: A longer message. The message is repeated several times. A longer message. The message is repeated several times. A longer message. The message is repeated several times.
Text 4: A short sentence.
Table 'black alt float-right'
Attributes: black alt float-right
Text 1: A short sentence.
Text 2: A longer message. The message is repeated several times. A longer message. The message is repeated several times.
Text 3: A longer message. The message is repeated several times. A longer message. The message is repeated several times. A longer message. The message is repeated several times.
Text 4: A short sentence.
Table 'red headline'
<th> <td>
Attributes: red headline
Text 1: A short sentence.
Text 2: A longer message. The message is repeated several times. A longer message. The message is repeated several times.
Text 3: A longer message. The message is repeated several times. A longer message. The message is repeated several times. A longer message. The message is repeated several times.
Text 4: A short sentence.
Table 'orange grid headline'
<th> <td>
Attributes: orange grid headline
Text 1: A short sentence.
Text 2: A longer message. The message is repeated several times. A longer message. The message is repeated several times.
Text 3: A longer message. The message is repeated several times. A longer message. The message is repeated several times. A longer message. The message is repeated several times.
Text 4: A short sentence.
Table 'yellow alt headline'
<th> <td>
Attributes: yellow alt headline
Text 1: A short sentence.
Text 2: A longer message. The message is repeated several times. A longer message. The message is repeated several times.
Text 3: A longer message. The message is repeated several times. A longer message. The message is repeated several times. A longer message. The message is repeated several times.
Text 4: A short sentence.
Table 'green alt grid headline'
<th> <td>
Attributes: green alt grid headline
Text 1: A short sentence.
Text 2: A longer message. The message is repeated several times. A longer message. The message is repeated several times.
Text 3: A longer message. The message is repeated several times. A longer message. The message is repeated several times. A longer message. The message is repeated several times.
Text 4: A short sentence.
Table 'cyan headline'
<th> <td>
Attributes: cyan headline
Text 1: A short sentence.
Text 2: A longer message. The message is repeated several times. A longer message. The message is repeated several times.
Text 3: A longer message. The message is repeated several times. A longer message. The message is repeated several times. A longer message. The message is repeated several times.
Text 4: A short sentence.
Table 'blue large grid headline'
<th> <td>
Attributes: blue large grid headline
Text 1: A short sentence.
Text 2: A longer message. The message is repeated several times. A longer message. The message is repeated several times.
Text 3: A longer message. The message is repeated several times. A longer message. The message is repeated several times. A longer message. The message is repeated several times.
Text 4: A short sentence.
Table 'magenta huge alt headline'
<th> <td>
Attributes: magenta huge alt headline
Text 1: A short sentence.
Text 2: A longer message. The message is repeated several times. A longer message. The message is repeated several times.
Text 3: A longer message. The message is repeated several times. A longer message. The message is repeated several times. A longer message. The message is repeated several times.
Text 4: A short sentence.
Table 'white center alt grid headline'
<th> <td>
Attributes: white center alt grid headline
Text 1: A short sentence.
Text 2: A longer message. The message is repeated several times. A longer message. The message is repeated several times.
Text 3: A longer message. The message is repeated several times. A longer message. The message is repeated several times. A longer message. The message is repeated several times.
Text 4: A short sentence.
Table 'gray headline'
<th> <td>
Attributes: gray headline
Text 1: A short sentence.
Text 2: A longer message. The message is repeated several times. A longer message. The message is repeated several times.
Text 3: A longer message. The message is repeated several times. A longer message. The message is repeated several times. A longer message. The message is repeated several times.
Text 4: A short sentence.
Table 'black grid headline'
<th> <td>
Attributes: black grid headline
Text 1: A short sentence.
Text 2: A longer message. The message is repeated several times. A longer message. The message is repeated several times.
Text 3: A longer message. The message is repeated several times. A longer message. The message is repeated several times. A longer message. The message is repeated several times.
Text 4: A short sentence.