Vorlage:Flexbox: Unterschied zwischen den Versionen
Aus drf-faq
					
										
					
					Mile (Diskussion | Beiträge)  (Flexbox. Aus https://wiki.uugrn.org/Vorlage:Flexbox übernommen, der ursprüngliche Autor dieser Vorlage im Herkunftswiki bin ich selbst.)  | 
				Mile (Diskussion | Beiträge)  K (→Varianten:  weitere.)  | 
				||
| (12 dazwischenliegende Versionen desselben Benutzers werden nicht angezeigt) | |||
| Zeile 1: | Zeile 1: | ||
| − | <includeonly><div style="margin:5px; margin-left:0px; {{{style}}};"><div style="background-color:{{{color|#136381}}};    | + | <includeonly><div style="margin:5px; margin-left:0px;    | 
| + |      -webkit-box-shadow:0px 1px 3px rgba(0,0,0,0.2);  | ||
| + |      box-shadow:0px 1px 3px rgba(0,0,0,0.2);  | ||
| + |      {{{style}}};">{{#if:{{{title}}}|<div style="background-color:{{{color|#136381}}};    | ||
      text-align:left;    |       text-align:left;    | ||
      color: {{{titlecolor|{{{bgcolor|white}}}}}};  |       color: {{{titlecolor|{{{bgcolor|white}}}}}};  | ||
      font-weight:bold; font-size:125%;    |       font-weight:bold; font-size:125%;    | ||
| − |       -  | + |       border-top-left-radius:3px; border-top-right-radius:3px;  | 
| + |      padding:3px; padding-left:5px; {{{titlestyle}}};">{{{title}}}</div>}}  | ||
<div style="padding: 5px;    | <div style="padding: 5px;    | ||
| − |       border: 1px solid {{{color|#136381}}}; 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}}};    | ||
| − | + |       {{#if:{{{title}}}|border-bottom-left-radius:3px; border-bottom-right-radius:3px;|border-radius:3px;}}  | |
      {{{textstyle}}};">  |       {{{textstyle}}};">  | ||
{{{text}}}  | {{{text}}}  | ||
| Zeile 50: | Zeile 54: | ||
Lorem ipsum dolor sit amet, ...  | Lorem ipsum dolor sit amet, ...  | ||
}}  | }}  | ||
| + | |||
| + | == Varianten ==  | ||
| + | * [[Vorlage:Aktuellbox]]  | ||
| + | * [[Vorlage:Hinweisbox]]  | ||
| + | * [[Vorlage:Warnbox]]  | ||
[[Kategorie:Artikelvorlage]]  | [[Kategorie:Artikelvorlage]]  | ||
</noinclude>  | </noinclude>  | ||
Aktuelle Version vom 14. Juni 2012, 07:25 Uhr
Vorlage zum leichten und einheitlichen Erstellen von flexibel parametrisierbaren Boxen.
Inhaltsverzeichnis
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, ...