Template:Infobox: Difference between revisions

From Valve Developer Community
Jump to navigation Jump to search
No edit summary
m (Added more entries and sections)
Line 46: Line 46:
   <div style="background:#232323; {{#if:{{{section5|}}}||border-top:1px solid #323232;}} color:white; padding:.3em; {{{entryid5style}}}"><b>{{{entryid5|}}}</b></div>
   <div style="background:#232323; {{#if:{{{section5|}}}||border-top:1px solid #323232;}} color:white; padding:.3em; {{{entryid5style}}}"><b>{{{entryid5|}}}</b></div>
   <div style="{{#if:{{{section5|}}}||border-top:1px solid #232323;}} padding:.3em; {{{entryinfo5style}}}">{{{entryinfo5|}}}</div>
   <div style="{{#if:{{{section5|}}}||border-top:1px solid #232323;}} padding:.3em; {{{entryinfo5style}}}">{{{entryinfo5|}}}</div>
</div>}}
| content5style = padding:0
| section6      = {{#if:{{{section6|}}}|<h4 style="font-size:14px; margin:0; padding:0;">{{{section6}}}</h4>|}}
| content6      = {{#ifeq:{{{entryid6|}}}|{{{entryinfo6|}}}||
<div style="display:grid; grid-template-columns:1fr 1fr;">
  <div style="background:#232323; {{#if:{{{section6|}}}||border-top:1px solid #323232;}} color:white; padding:.3em; {{{entryid6style}}}"><b>{{{entryid6|}}}</b></div>
  <div style="{{#if:{{{section6|}}}||border-top:1px solid #232323;}} padding:.3em; {{{entryinfo6style}}}">{{{entryinfo6|}}}</div>
</div>}}
| content6style = padding:0
| section7      = {{#if:{{{section7|}}}|<h4 style="font-size:14px; margin:0; padding:0;">{{{section7}}}</h4>|}}
| content7      = {{#ifeq:{{{entryid7|}}}|{{{entryinfo7|}}}||
<div style="display:grid; grid-template-columns:1fr 1fr;">
  <div style="background:#232323; {{#if:{{{section7|}}}||border-top:1px solid #323232;}} color:white; padding:.3em; {{{entryid7style}}}"><b>{{{entryid7|}}}</b></div>
  <div style="{{#if:{{{section7|}}}||border-top:1px solid #232323;}} padding:.3em; {{{entryinfo7style}}}">{{{entryinfo7|}}}</div>
</div>}}
| content5style = padding:0
| section8      = {{#if:{{{section8|}}}|<h4 style="font-size:14px; margin:0; padding:0;">{{{section8}}}</h4>|}}
| content8      = {{#ifeq:{{{entryid8|}}}|{{{entryinfo8|}}}||
<div style="display:grid; grid-template-columns:1fr 1fr;">
  <div style="background:#232323; {{#if:{{{section8|}}}||border-top:1px solid #323232;}} color:white; padding:.3em; {{{entryid8style}}}"><b>{{{entryid8|}}}</b></div>
  <div style="{{#if:{{{section8|}}}||border-top:1px solid #232323;}} padding:.3em; {{{entryinfo8style}}}">{{{entryinfo8|}}}</div>
</div>}}
| content8style = padding:0
| section9      = {{#if:{{{section9|}}}|<h4 style="font-size:14px; margin:0; padding:0;">{{{section5}}}</h4>|}}
| content9      = {{#ifeq:{{{entryid9|}}}|{{{entryinfo9|}}}||
<div style="display:grid; grid-template-columns:1fr 1fr;">
  <div style="background:#232323; {{#if:{{{section9|}}}||border-top:1px solid #323232;}} color:white; padding:.3em; {{{entryid9style}}}"><b>{{{entryid9|}}}</b></div>
  <div style="{{#if:{{{section9|}}}||border-top:1px solid #232323;}} padding:.3em; {{{entryinfo9style}}}">{{{entryinfo9|}}}</div>
</div>}}
| content9style = padding:0
| section10    = {{#if:{{{section10|}}}|<h4 style="font-size:14px; margin:0; padding:0;">{{{section10}}}</h4>|}}
| content10    = {{#ifeq:{{{entryid10|}}}|{{{entryinfo10|}}}||
<div style="display:grid; grid-template-columns:1fr 1fr;">
  <div style="background:#232323; {{#if:{{{section10|}}}||border-top:1px solid #323232;}} color:white; padding:.3em; {{{entryid10style}}}"><b>{{{entryid10|}}}</b></div>
  <div style="{{#if:{{{section10|}}}||border-top:1px solid #232323;}} padding:.3em; {{{entryinfo10style}}}">{{{entryinfo10|}}}</div>
</div>}}
</div>}}
| content5style = padding:0
| content5style = padding:0
}}</includeonly></onlyinclude>{{doc}}[[Category:Metatemplates]]
}}</includeonly></onlyinclude>{{doc}}[[Category:Metatemplates]]

Revision as of 19:32, 31 May 2023

English (en)Deutsch (de)Esperanto (eo)Español (es)Français (fr)Suomi (fi)Hrvatski (hr)Magyar (hu)Italiano (it)日本語 (ja)한국어 (ko)Nederlands (nl)Polski (pl)Português (pt)Português do Brasil (pt-br)Русский (ru)Slovenčina (sk)Svenska (sv)Türkçe (tr)Українська (uk)Tiếng Việt (vi)中文 (zh)中文(臺灣) (zh-tw)
Curly brackets white.pngTemplate Documentation [view] [edit]
Icon-translate.png Available doc translations
View
Page history
Gnome app science.png
This template uses a Testcases subpage
You can test how this page looks with it's different skins and parsers.

This is a sub-metatemplate of {{sidebar}} that is designed to help create infobox templates.

Sub-metatemplates

This template has 1 sub-metatemplate called {{infobox template}}.

Sandbox

The sandbox for this page can be found at the sandbox subpage.

Testcases

Testcases for this template can be located on the testcases subpage.

Copy and Paste

{{Infobox | header = | image = | section1 = | entryid1 = | entryinfo1 = | footer = }}

Usage & Preview

{{Infobox}}
Parameter Description Example
{{{header}}} Header content
| header = Foo bar
{{{section <1-2>}}} Main content section dividers
| section1 = Test
{{{entryid <1-2>}}} Entry idboxes
| entryid1 = Example
{{{entryinfo <1-2>}}} Entry infoboxes
| entryinfo2 = Placeholder
{{{footer}}} Footer content
| footer = Placeholder
{{{width}}} Width of the sidebar container and sidebar image
| width = 320px
Image parameters
{{{image}}} Sidebar image
| image = Software Cover - The Lab.jpg
{{{imagewidth}}} Sidebar image width
| imagewidth = 64px
{{{imagelink}}} Sidebar image link
| imagelink = Portal 2
Style parameters
{{{headerstyle}}} Header styling
| headerstyle = font-family:sans-serif;
{{{entryid <1-20> style}}} Entry idbox styling
| entryid1style = background:none;
{{{entryinfo <1-20> style}}} Entry infobox styling
| entryinfo1style = margin:.3em;
{{{footerstyle}}} Footer styling
| footerstyle1 = text-align:right;
{{{float}}} For specifying how or if the sidebar will float
| float = left
{{{header}}}
Software Cover - The Lab.jpg

{{{section1}}}

{{{entryid1}}}
{{{entryinfo1}}}
{{{entryid2}}}
{{{entryinfo2}}}
{{{footer}}}
Hierarchy: Sidebar / Infobox