I have a bunch of dynamic images in my HTML. I want to apply certain limits to its size depending on the size of the image itself. For instance this is my code now :
.question_image {
max-width: 300px;
max-width: 300px;
}
But I want something like :
.question_image {
if ( image.height < 50px )
max-width: 80%;
else
max-width: 300px;
max-width: 300px;
}
My only problem is I need to be done with plain CSS, not SASS.
Is this posible?