Template:CodeBlock: Difference between revisions
Jump to navigation
Jump to search
mNo edit summary |
No edit summary |
||
Line 1: | Line 1: | ||
<onlyinclude><includeonly><!-- | <onlyinclude><includeonly><!-- | ||
--><div style=" | --><div style="overflow:hidden;background-color:{{#switch:{{{style|}}}|1=rgba(0,0,0,.1)|rgba(0,0,0,.3)}};{{#switch:{{{style|}}}|1=border:1px solid rgba(48,48,48,1);|}}border-radius:6px; font-family:monospace,monospace; line-height:1.125rem; text-indent:0; white-space:pre-wrap; margin: {{{margin|.5em 0 0 0}}}"><!-- | ||
-->{{#if:{{{src|{{{lang|}}}}}}|<div style="background-color:rgba(0,0,0,.1); border-bottom:1px solid rgba(255,255,255,.1); font-family:monospace,monospace;line-height:1.125rem; text-indent:0; white-space:pre-wrap; padding:.5em"><!-- | -->{{#if:{{{src|{{{lang|}}}}}}|<div style="display:flex;justify-content:space-between;background-color:rgba(0,0,0,.1); border-bottom:1px solid rgba(255,255,255,.1); font-family:monospace,monospace;line-height:1.125rem; text-indent:0; white-space:pre-wrap; padding:.5em"><!-- | ||
-->{{{src|The source was not specified}}}<!-- | --><div>{{{src|The source was not specified}}}<span style=user-select:none></span></div><!-- | ||
-->{{#if:{{{lang|}}}|<div | -->{{#if:{{{lang|}}}|<div>{{#switch:{{{lang}}}|plain=Plain text|html=HTML|css=CSS|scss=SCSS|less=LESS|js=JavaScript|json=JSON|php=PHP|c=C|cs=C#|cpp=C++|pascal=Pascal|python=Python|java=Java|squirrel=Squirrel|lua=Lua|glua=gLua|{{{lang}}}}}<span style=user-select:none></span></div>}}<!-- | ||
--></div>}}<!-- | --></div>}}<!-- | ||
--><div style="display:flex"><!-- | --><div><div style="display:flex;max-height:{{{height|auto}}};overflow:auto"><!-- | ||
-->{{#if:{{{lines|}}}|<div style="position:sticky;left:0;padding:.6em 0 .5em 0;background-color:rgb(24,24,24);border-right:1px solid rgb(48,48,48);height:100%"><ol start="{{{start|1}}}" style="text-align:right;pointer-events:none;white-space:nowrap;list-style-position:inside;margin-left:8px;margin-top:0;user-select:none;margin-right:-10px;text-indent:0">{{padright:|{{#expr:5 * {{{lines}}}}}|<li> }}{{#ifexpr:{{{lines}}} > 100 |{{padright:|{{#expr:5 * ({{{lines}}} - 100)}}|<li> }}}}{{#ifexpr:{{{lines}}} > 200 |{{padright:|{{#expr:5 * ({{{lines}}} - 200)}}|<li> }}}}{{#ifexpr:{{{lines}}} > 300 |{{padright:|{{#expr:5 * ({{{lines}}} - 300)}}|<li> }}}}{{#ifexpr:{{{lines}}} > 400 |{{padright:|{{#expr:5 * ({{{lines}}} - 400)}}|<li> }}}}</ol></div>}}<!-- | |||
--><div style="padding:.55em | --><div style="padding:.55em .5em;text-indent:0;line-height:1.6em;white-space:pre;width:100%;height:100%;">{{{1|}}}</div><!-- | ||
--></div><!-- | --></div></div><!-- | ||
--></div></includeonly></onlyinclude>{{ | --></div></includeonly></onlyinclude>{{Doc}} |
Revision as of 17:08, 17 February 2023
The above documentation is transcluded from Template:CodeBlock/doc. (Edit | Page history)
Editors can experiment in this template's sandbox (edit) and testcases (create) pages.
Editors can experiment in this template's sandbox (edit) and testcases (create) pages.