Template:Clickable button: Difference between revisions

From WWII Archives

wc>Zhuyifei1999
m (- extra linebreak)
 
m (1 revision imported)
 
(2 intermediate revisions by 2 users not shown)
Line 1: Line 1:
<onlyinclude>{{#if:{{{3|{{{external|}}}}}}
<span class="mw-ui-button {{#switch: {{{color|white}}} | red = mw-ui-destructive | green = mw-ui-progressive | white = | blue = mw-ui-progressive}}" role="button" aria-disabled="false">{{{text|{{{1|Button text}}}}}}</span><noinclude>{{Documentation}}
  | <span class="plainlinks" {{#if:{{{id|}}}|id="{{{id}}}"}}>[{{{1|{{{target|//parameter_target_is_empty.de}}}}}} <span class="submit ui-button ui-widget ui-state-default ui-corner-all {{Clickable button/iconclass
</noinclude>
    |{{{4|{{{iconPrimary|}}}}}}
    |{{{5|{{{iconSecondary|}}}}}}
    |{{{2|{{{text|<noinclude>x</noinclude>}}}}}}
  }} {{{class|}}}" role="button" aria-disabled="false"><!-- // -->{{#if:{{{4|{{{iconPrimary|}}}}}}
  |<span class="ui-button-icon-primary ui-icon {{{4|{{{iconPrimary}}}}}}">&nbsp;</span>
  }}<span class="ui-button-text">{{{2|{{{text|Parameter '''text''' is empty}}}}}}</span>{{#if:{{{5|{{{iconSecondary|}}}}}}
  |<span class="ui-button-icon-secondary ui-icon {{{5|{{{iconSecondary|}}}}}}">&nbsp;</span>
  }}</span>]</span><!--
  -->
  | [[{{{1|{{{target|Parameter target is empty!}}}}}}|<span class="submit ui-button ui-widget ui-state-default ui-corner-all {{Clickable button/iconclass
    |{{{4|{{{iconPrimary|}}}}}}
    |{{{5|{{{iconSecondary|}}}}}}
    |{{{2|{{{text|<noinclude>x</noinclude>}}}}}}
  }} {{{class|}}}" role="button" aria-disabled="false" {{#if:{{{id|}}}|id="{{{id}}}"}}><!-- // -->{{#if:{{{4|{{{iconPrimary|}}}}}}
  |<span class="ui-button-icon-primary ui-icon {{{4|{{{iconPrimary}}}}}}">&nbsp;</span>
  }}<span class="ui-button-text">{{{2|{{{text|Parameter '''text''' is empty}}}}}}</span>{{#if:{{{5|{{{iconSecondary|}}}}}}
  |<span class="ui-button-icon-secondary ui-icon {{{5|{{{iconSecondary|}}}}}}">&nbsp;</span>
  }}</span>]]
}}<!--
 
 
--></onlyinclude>
{{documentation}}
<!-- Add categories and interwikis to Template:Clickable button/doc subpage, not here! -->

Latest revision as of 18:32, 16 March 2023

Button text

File:Test Template Info-Icon.svg Template documentationview · edit · history · purge ]
This documentation is transcluded from Template:Clickable button/doc.


Example

Button text → {{Clickable button|color=white}}

Button text → {{Clickable button|color=red}}

Button text → {{Clickable button|color=blue}}

text → [[target|{{Clickable button|text}}]] (for links. To add links, transclude this template inside wikilinks after the pipebar: [[target title|{{Clickable button|text}}]]. Or better use {{clickable button 2}} which adds links automatically)

Templatedata

Creates a OOUI styled button.

Template parameters

This template prefers inline formatting of parameters.

ParameterDescriptionTypeStatus
Labeltext 1

no description

Contentrequired
Color of the buttoncolor

Can be blue (progressive), red (destructive) or white

Stringsuggested

See also