Template:Infobox country/imagetable: Difference between revisions

From TEPwiki, Urth's Encyclopedia
Jump to navigation Jump to search
Content added Content deleted
(used table-cell instead of inline-block to prevent issues when the symbol is a similar width to the flag.)
(tidied up syntax and added 5px padding around images, especially beneficial for articles with two flags. Eg Scotland and New Caledonia.)
Line 1: Line 1:
{{#if:{{both|{{{image1a|}}}{{{image1b|}}}|{{{image2|}}}}}
{{#if:{{both|{{{image1a|}}}{{{image1b|}}}|{{{image2|}}}}}|
|<div style="display:table; width:100%;><div style="display:table-row;">
<div style="display:table; width:100%;">
<div style="display:table-cell;vertical-align:middle;width:58%;text-align:center;">
<div style="display:table-cell; width:58%; vertical-align:middle; padding-left:5px;">
<div class=center>{{{image1a|}}}</div><div class=center>{{{image1b|}}}</div>
{{#if:{{{image1a|}}}|<div style="padding-bottom:3px;">{{{image1a|}}}</div>}}{{#if:{{{image1b|}}}|<div style="padding: 2px 0px 3px;">{{{image1b|}}}</div>}}
<div style="font-size:85%; text-align:center; margin-top:2px;">{{{caption1|}}}</div>
<div style="font-size:85%;">{{{caption1|}}}</div>
</div>
</div>
<div style="display:table-cell;vertical-align:middle;width:auto;text-align:center;">
<div style="display:table-cell; vertical-align:middle; padding: 0px 5px;">
<div class=center>{{{image2|}}}</div>
<div style="padding-bottom:3px;">{{{image2|}}}</div>
<div style="font-size:85%; text-align:center; margin-top:2px;">{{{caption2|}}}</div>
<div style="font-size:85%;">{{{caption2|}}}</div>
</div></div></div>
</div>
</div>
|{{#if:{{{image1a|}}}{{{image1b|}}}|{{{image1a|}}}{{{image1b|}}}<div class=center style="font-size:85%; text-align:center; margin-top:2px;">{{{caption1}}}</div>
<!--else:-->|
}}{{#if:{{{image2|}}}|{{{image2|}}}<div class=center style="font-size:85%; text-align:center; margin-top:2px;">{{{caption2}}}</div>
{{#if:{{{image1a|}}}{{{image1b|}}}|
}}
<div style="display:table; width:100%;">
{{#if:{{{image1a|}}}|<div style="display:table-cell; vertical-align:middle; padding: 0px 5px 3px;">{{{image1a|}}}</div>}}{{#if:{{{image1b|}}}|<div style="display:table-cell; vertical-align:middle; padding: 0px 5px 3px 0px;">{{{image1b|}}}</div>}}
</div>
<div style="font-size:85%;">{{{caption1}}}</div>
}}
{{#if:{{{image2|}}}|
<div style="padding: 0px 5px;">
<div style="padding-bottom:3px;">{{{image2|}}}</div>
<div style="font-size:85%;">{{{caption2}}}</div>
</div>
}}
}}<noinclude>
}}<noinclude>
{{documentation|content=
{{documentation|content=

Revision as of 08:15, 18 July 2017