1
1
mirror of https://github.com/aelve/guide.git synced 2024-12-18 18:31:45 +03:00
guide/templates/utils/img-controls.widget
2016-09-14 01:02:32 +03:00

31 lines
911 B
Plaintext
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

Description
============================================================
Various controls:
* img-button an image that is a link
* small-control one of small image buttons used for traits and so on
Both take the following arguments:
* src link to the image
* title title text
* action the JS action to execute on click, must end with a ';'
* class optional "class" argument
HTML: img-button
============================================================
<a href="#" {{# class}}class="{{.}}"{{/ class}} onclick="{{action}} return false;"><img src="{{src}}" alt="{{title}}" title="{{title}}"></a>
HTML: small-control
============================================================
{{> img-button class=[|small-control{{# class}} {{.}}{{/ class}}|] }}
CSS
============================================================
.small-control img {
opacity: 0.5;
width: 12px;
}