Vorlage:Flexbox: Unterschied zwischen den Versionen

Aus drf-faq
Wechseln zu: Navigation, Suche
K
K (css: einmal padding zu viel)
Zeile 12: Zeile 12:
 
     border: 1px solid {{{color|#136381}}}; {{#if:{{{title}}} | border-top-width:0px; }}
 
     border: 1px solid {{{color|#136381}}}; {{#if:{{{title}}} | border-top-width:0px; }}
 
     color: {{{textcolor|black}}}; background-color:{{{bgcolor|#f6fcfe}}};  
 
     color: {{{textcolor|black}}}; background-color:{{{bgcolor|#f6fcfe}}};  
     padding:5px; -moz-border-radius: {{#if:{{{title}}}|0px 0px|3px 3px}} 3px 3px;
+
     -moz-border-radius: {{#if:{{{title}}}|0px 0px|3px 3px}} 3px 3px;
 
     {{#if:{{{title}}}|border-bottom-left-radius:3px; border-bottom-right-radius:3px;|border-radius:3px;}}
 
     {{#if:{{{title}}}|border-bottom-left-radius:3px; border-bottom-right-radius:3px;|border-radius:3px;}}
 
     {{{textstyle}}};">
 
     {{{textstyle}}};">

Version vom 15. Januar 2011, 16:02 Uhr

Vorlage zum leichten und einheitlichen Erstellen von flexibel parametrisierbaren Boxen.

Einschränkungen

  • Keiner der Parameter darf das |-Zeichen (Pipe) enthalten, da dies als besonderes Zeichen zur Separierung der einzelnen Parameter voneinander fungiert. Diese Einschränkung bewirkt insbesondere, dass das Wiki-Markup zum Erstellen von Tabellen nicht funktioniert.

Vorlagenparameter

Parameter Beschreibung
style CSS-Fragment für das Gesamtobjekt (optional, z.B. float:right;width:200px;)
bgcolor Hintergrundfarbe (optional, default: #f6fcfe)
color Rahmenfarbe und Titelzeile (optional, default: #136381)
text Boxinhalt
textcolor Textfarbe Boxinhalt (optional, default: black)
textstyle CSS-Fragment für den Boxinhalt (optional)
title Boxüberschrift
titlecolor Textfarbe der Titelzeile (optional, default: {{{bgcolor}}} wenn gesetzt, sonst white)
titlestyle CSS-Fragment für Titelzeile (optional)

Beispiel

{{Flexbox|bgcolor=#fffbf5|color=#f19000|title=Testbox 123|text=
Lorem ipsum dolor sit amet, ...
}}

Dies ergibt die folgende Box:

Testbox 123

Lorem ipsum dolor sit amet, ...

Varianten