Template:Clickable button 2: Difference between revisions

condense style code
(Allow custom styling on pages that aren't selflinks)
(condense style code)
Line 2:
|{{{url}}}
|[{{{1|}}}{{!}}
}}<span class="{{#switch:{{lc:{{{class|}}}}}|ui-button-green|ui-button-blue|ui-button-red=submit ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only ui-button-text|#default=mw-ui-button}} {{{class|}}}" role="button" aria-disabled="false" style="{{#ifeq:{{FULLPAGENAME:{{{1}}}}}|{{FULLPAGENAME}}|style="cursor: default;
{{#switch:{{{class|}}}
| ui-button-blue | mw-ui-progressive = background-color: #2962CB;
Line 8:
| ui-button-red | mw-ui-destructive = background-color: #A6170F;
| #default = background-color: #CCC; color: #666;
}}}} {{{style|}}}">{{#if:{{{url|}}}
|style="{{{style|}}}"}}>{{#if:{{{url|}}}
|{{#if:{{{1|}}}
|{{{1}}}
Anonymous user