add a very small image size for catalog

This commit is contained in:
czaks 2014-09-20 06:40:43 +02:00
parent 56e55d157a
commit ac888a769d
3 changed files with 14 additions and 6 deletions

View File

@ -7,12 +7,9 @@ if (active_page == 'catalog') $(function(){
$("#image_size").change(function(){
var value = this.value, old;
if (value == "small") {
old = "large";
} else {
old = "small";
}
$(".grid-li").removeClass("grid-size-"+old);
$(".grid-li").removeClass("grid-size-vsmall");
$(".grid-li").removeClass("grid-size-small");
$(".grid-li").removeClass("grid-size-large");
$(".grid-li").addClass("grid-size-"+value);
});

View File

@ -533,6 +533,16 @@ form.ban-appeal textarea {
margin-left: -20px;
}
.theme-catalog div.grid-size-vsmall img {
max-width: 100%;
}
.theme-catalog div.grid-size-vsmall {
width: 100px;
max-width: 100px;
max-height: 150px;
}
.theme-catalog div.grid-size-small {
width: 200px;
max-width: 200px;

View File

@ -33,6 +33,7 @@
<span>{% trans 'Image size' %}: </span>
<select id="image_size" style="display: inline-block">
<option value="vsmall">{% trans 'Very small' %}</option>
<option selected value="small">{% trans 'Small' %}</option>
<option value="large">{% trans 'Large' %}</option>
</select>