The Figure widget is used to place single image. Please use Gallery for multiple images.
<figure data-am-widget="figure" class="am am-figure am-figure-default " data-am-figure="{ pureview: 'true' }">
<img src="https://amazeui.github.io/media/i/demos/pure-1.jpg?imageView2/0/w/640" data-rel="https://amazeui.github.io/media/i/demos/pure-1.jpg" alt="春天的花开秋天的风以及冬天的落阳"/>
<figcaption class="am-figure-capition-btm">
春天的花开秋天的风以及冬天的落阳
</figcaption>
</figure>
<body>
of the Amaze UI HTML template(Download);The Handlebars partial of Figure widget is figure
. See Accordion for more details
Data binding
button on the right panel, and bind data using following format.var data = {
"img": "", // Path of image.
"imgAlt": "", // Alternative text. If this is empty then use figcaption.
"figcaption": "" // The caption of image. Shown at the bottom of image.
};
return data;
If the image is too big, use the thumbnail in img
, and use the original image in rel
.
{
"id": "",
"className": "",
"theme": "",
"options": {
"figcaptionPosition": "bottom", // Caption position: top | bottom
"zoomble": false // Whether allow zooming: ['auto'|true|false]
// 'auto' - Judge by the width of image. Allow zooming if the width of image is larger than viewport.
// This option will be used as the data-am-figure="{pureview: {{zoomable}} }" option in pureview.
},
"content": [
{
"img": "", // Path of image(thumbnail)
"rel": "", // Path of original image.
"imgAlt": "", // Alternative text. If this is empty then use figcaption.
"figcaption": "" // Caption.
}
]
}