Template:Sidebar/testcases: Difference between revisions

From Valve Developer Community
Jump to navigation Jump to search
mNo edit summary
No edit summary
Line 34: Line 34:
|}
|}


== Advanced tests ==
== Section tests ==
{|class="standard-table" | style="text-align:center; width:100%;"
|-
! style="width:100%" |{{Dictionary/common|Desc}}
! {{Dictionary/common|Preview}}
|-
| style="background:#282828; padding-inline:.5em;" | {{capsule|style=2|With one section only}}
| style="padding-block:.5em;" | {{sidebar|section1=Section 1}}
|-
| style="background:#282828; padding-inline:.5em;" | {{capsule|style=2|With two sections only}}
| style="padding-block:.5em;" | {{sidebar|section1=Section 1|section2=Section 2}}
|-
| style="background:#282828; padding-inline:.5em;" | {{capsule|style=2|With two sections, with section 2 being skipped}}
| style="padding-block:.5em;" | {{sidebar|section1=Section 1|section3=Section 3}}
|}


== Content tests ==
{|class="standard-table" | style="text-align:center; width:100%;"
{|class="standard-table" | style="text-align:center; width:100%;"
|-
|-
Line 41: Line 56:
! {{Dictionary/common|Preview}}
! {{Dictionary/common|Preview}}
|-
|-
| style="background:#282828; padding-inline:.5em;" | {{capsule|style=2|With header, footer, section and content parameters}}
| style="background:#282828; padding-inline:.5em;" | {{capsule|style=2|With one content box only}}
| style="padding-block:.5em;" | {{sidebar
| style="padding-block:.5em;" | {{sidebar|content1=Content 1}}
                                | header      = Header
                                | section1    = Section
                                | content1   = Content
                                | section2    = Section
                                | content2    = Content   
                                | footer      = Footer                         
                                }}
|-
|-
|-
| style="background:#282828; padding-inline:.5em;" | {{capsule|style=2|With a variety of parameters}}
| style="background:#282828; padding-inline:.5em;" | {{capsule|style=2|With two content boxes only}}
| style="padding-block:.5em;" | {{sidebar
| style="padding-block:.5em;" | {{sidebar|content1=Content 1|content2=Content 2}}
                                | float      = none
                                | image      = Missing entity icon (pink).png
                                | imagewidth  = 64px
                                | header      = Header
                                | section1    = Section 
                                | content1   = Content    
                                | footer      = Footer                         
                                }}
|-
|-
| style="background:#282828; padding-inline:.5em;" | {{capsule|style=2|With two content boxes, with content box 2 being skipped}}
| style="padding-block:.5em;" | {{sidebar|content1=Content 1|content3=Content 3}}
|}
|}

Revision as of 21:21, 29 May 2023

Gnome app science.png
This is the template test cases page for Template:Sidebar. Purge this page in order to update the examples, if the template itself was recently edited.
If there are too many examples of a complicated template, later transclusions of such template may break due to the limitations of the Mediawiki software, or can cause the page itself to load very slow; See the HTML comment "NewPP limit Report" on the rendered page.
You can also use Special:ExpandTemplates to examine the results of template use cases.


Basic tests

Description Preview
With no parameters
With header parameter only
Header
With content parameter only
Content
With footer parameter only
Footer

Image tests

Description Preview
With image parameter only
[[File:Software Cover - The Lab.jpg
300px]]
With image parameter and imagewidth parameter
[[File:Missing entity icon.png
64px]]

Section tests

Description Preview
With one section only
Section 1
With two sections only
Section 1
Section 2
With two sections, with section 2 being skipped
Section 1
Section 3

Content tests

Description Preview
With one content box only
Content 1
With two content boxes only
Content 1
Content 2
With two content boxes, with content box 2 being skipped
Content 1
Content 3