Template:Location map: Difference between revisions
From Zoophilia Wiki
Jump to navigationJump to search
meta>Plastikspork Per discussion on the talk page, this should not break anything and will allow for non-rectangular projections to work as well, matching German Wikipedia |
meta>Plastikspork m Per request, remove extra padding when caption is not present |
||
Line 1: | Line 1: | ||
<includeonly><div style="width:{{#expr:{{#if:{{{width|}}}|{{{width}}}|240}} + 2 }}px; | <includeonly><div style="{{#if: {{{caption|}}} | ||
| width:{{#expr:{{#if:{{{width|}}}|{{{width}}}|240}} + 2 }}px; padding: 3px;{{#ifeq: {{{border|}}} | none || border: 1px solid {{#if: {{{border|}}} | {{{border}}} | #CCC }};}} margin: 3px; | |||
| width:{{#if:{{{width|}}}|{{{width}}}|240}}px; | |||
}} float:{{#switch:{{{float|}}}|"center"|center=none|"left"|left=left|"right"|right=right|"none"|none=none|right}}; clear:{{#switch:{{{float|}}}|"center"|center=both|"left"|left=left|"right"|right=right|"none"|none=none|right}};{{#if: {{{caption|}}} | background:#F9F9F9; }}"><div style="position: relative;{{#if: {{{caption|}}} | }} float:{{#switch:{{{float|}}}|"center"|center=none|"left"|left=left|"right"|right=right|"none"|none=none|right}}; clear:{{#switch:{{{float|}}}|"center"|center=both|"left"|left=left|"right"|right=right|"none"|none=none|right}};{{#if: {{{caption|}}} | background:#F9F9F9; }}"><div style="position: relative;{{#if: {{{caption|}}} | ||
| {{#ifeq: {{{border|}}} | none || border: 1px solid {{#if: {{{border|}}} | {{{border}}} | #CCC}};}} | | {{#ifeq: {{{border|}}} | none || border: 1px solid {{#if: {{{border|}}} | {{{border}}} | #CCC}};}} |