Difference between revisions of "Template:B"

From ALttP Speedrunning Wiki
Jump to: navigation, search
(Replaced content with "{{#invoke:SNES button|main}}<noinclude>{{Documentation}}</noinclude>")
 
(11 intermediate revisions by the same user not shown)
Line 1: Line 1:
{{#css:
+
{{#invoke:SNES button|main}}<noinclude>{{Documentation}}</noinclude>
.snes-button,
 
.snes-button-face,
 
.snes-button-mid,
 
.snes-button-bumper {
 
display: inline-block;
 
text-align: center;
 
color: white;
 
border: 2px solid;
 
border-left: none;
 
border-top: none;
 
border-radius: 20px;
 
text-transform: capitalize;
 
}
 
 
 
.snes-button-face,
 
.snes-button-A,
 
.snes-button-B,
 
.snes-button-X,
 
.snes-button-Y {
 
width: 22px;
 
height: 22px;
 
font-weight: bold;
 
}
 
 
 
.snes-button-A {
 
background: #DA3948;
 
border-color: #610102;
 
}
 
 
 
.snes-button-B {
 
background: #FEBB52;
 
border-color: #3E0A00;
 
}
 
 
 
.snes-button-X {
 
background: #00489F;
 
border-color: #000A35;
 
}
 
 
 
.snes-button-Y {
 
background: #00916A;
 
border-color: #00331B;
 
}
 
 
 
.snes-button-bumper {
 
width: 40px;
 
height: 16px;
 
padding-bottom: 2px;
 
font-weight: bold;
 
border-color: #8D8D8D;
 
background: #B8B8A8;
 
}
 
 
 
.snes-button-L {
 
border-radius: 15px 0 0 0;
 
}
 
 
 
.snes-button-R {
 
border-radius: 0 15px 0 0;
 
}
 
 
 
.snes-button-mid,
 
.snes-button-Start,
 
.snes-button-Select {
 
width: 60px;
 
height: 12px;
 
padding-bottom: 8px;
 
background: #4B545B;
 
border-color: #050704;
 
font-variant: small-caps;
 
}
 
 
 
 
 
.snes-button-dpad {
 
display: inline-block;
 
width: 42px;
 
height: 42px;
 
}
 
 
 
.snes-button-dpad-mid {
 
display: block;
 
position: relative;
 
width: 14px;
 
height: 14px;
 
background: #000000;
 
border-radius: 20px;
 
z-index: 9000;
 
left: 14px;
 
top: 13px;
 
}
 
 
 
.snes-button-dpad-vert,
 
.snes-button-dpad-horz {
 
position: relative;
 
display: block;
 
background: #595E62;
 
border-radius: 3px;
 
border-style: solid;
 
border-width: 0;
 
border-color: #FF8080;
 
}
 
 
 
.snes-button-dpad-vert {
 
left: 14px;
 
width: 14px;
 
height: 42px;
 
min-height: 14px;
 
max-height: 42px;
 
}
 
 
 
.snes-button-dpad-up .snes-button-dpad-vert {
 
height: 28px;
 
border-top-width: 14px;
 
}
 
 
 
.snes-button-dpad-down .snes-button-dpad-vert {
 
height: 28px;
 
border-bottom-width: 14px;
 
}
 
 
 
.snes-button-dpad-up.snes-button-dpad-down .snes-button-dpad-vert {
 
height: 14px;
 
border-top-width: 14px;
 
}
 
 
 
.snes-button-dpad-horz {
 
bottom: 28px;
 
height: 14px;
 
min-width: 14px;
 
max-width: 42px;
 
}
 
 
 
.snes-button-dpad-left .snes-button-dpad-horz {
 
border-left-width: 14px;
 
}
 
 
 
.snes-button-dpad-right .snes-button-dpad-horz {
 
border-right-width: 14px;
 
}
 
 
 
.snes-button-dpad .snes-button-dpad-templatearg {
 
display: none;
 
}
 
 
 
}}{{#invoke:SNES button|main}}<noinclude>{{Documentation}}</noinclude>
 

Latest revision as of 12:56, 26 November 2018

Template documentation[view] [edit] [history] [purge]

Makes SNES buttons pretty.

{{B|A}} A
{{B|B}} B
{{B|X}} X
{{B|Y}} Y
{{B|L}} L
{{B|R}} R
{{B|Start}} Start
{{B|Select}} Select
{{B|Directional}} directional
{{B|D}} d
{{B|^}} ^
{{B|v}} v
{{B|<}} <
{{B|>}} >
{{B|^<}} ^<
{{B|^>}} ^>
{{B|^v}} ^v
{{B|v<}} v<
{{B|v>}} v>
{{B|^<}} ^<
{{B|^v<>}} ^v<>

Chaining

Multiple buttons can be displayed by a single template call, with several delimiters being recognized as special text.

{{B|A|B|<|>}} AB<>
{{B|A|+|B||+|<^}} A+B+<^
{{B|A|,|B|,|<|,|>}} A,B,<,>
{{B|A|;|B|;|<|;|>}} A;B;<;>