Template:Outdent: Difference between revisions
Content added Content deleted
en.wikipedia.org>Dinoguy1000 (documentation says this shouldn't be substed (which I didn't see before making my last edit); fix the problem with an empty first parameter causing an error) |
en.wikipedia.org>Dinoguy1000 (fix values of 0 and > 40 causing weird input (in those cases the template will now fall back on its default value of 10)) |
||
Line 1: | Line 1: | ||
<span class="outdent-template" style="display:block; margin-top:-0.5em; color:#AAA;"><!-- |
<span class="outdent-template" style="display:block; margin-top:-0.5em; color:#AAA;"><!-- |
||
--><span style="display:inline-block; overflow:hidden;">{{#if:{{{reverse|}}}|└|┌}}</span><!-- |
--><span style="display:inline-block; overflow:hidden;">{{#if:{{{reverse|}}}|└|┌}}</span><!-- |
||
--><span style="display:inline-block; overflow:hidden; word-wrap:normal; width:{{#switch:{{{1 |
--><span style="display:inline-block; overflow:hidden; word-wrap:normal; width:{{#switch:{{{1}}} |
||
|:=0.8 |
|:=0.8 |
||
|::=2.4 |
|::=2.4 |
||
Line 22: | Line 22: | ||
|:::::::::::::::::::=29.6 |
|:::::::::::::::::::=29.6 |
||
|::::::::::::::::::::=31.2 |
|::::::::::::::::::::=31.2 |
||
|#default={{ #expr: {{ # |
|#default={{ #expr: {{ #iferror: {{ #ifexpr: {{{1}}} > 0 and {{{1}}} < 40 | {{{1}}} | 10 }} | 10 }} * 1.6 - 0.8 }} }}em;"><!-- |
||
-->────────────────────────────────────────────────────────────────────────────────────────────────────</span><!-- |
-->────────────────────────────────────────────────────────────────────────────────────────────────────</span><!-- |
||
--><span style="display:inline-block; overflow:hidden;">{{#if:{{{reverse|}}}|┐|┘}}</span><!-- |
--><span style="display:inline-block; overflow:hidden;">{{#if:{{{reverse|}}}|┐|┘}}</span><!-- |