JSFiddle - React, Tailwind, and code Playground

HTML

<div class="container"></div>
<div class="container"></div>
<div class="container"></div>

CSS

.container {
    background-size: auto 100%;
    background-position: center;
    background-repeat: no-repeat;
    width: 100px;
    height: 100px;
    overflow: hidden;
    border: black solid 1px;
    margin: 10px;
}
.container img {
    height: 100%;
}
.container:first-child {
    background-image: url('http://static.ddmcdn.com/gif/storymaker-best-hubble-space-telescope-images-20092-514x268.jpg');
}
.container:first-child + .container {
    background-image: url('http://chennaionline.com/images/gallery/2013/June/20110623010938/Singam2_Suriya_Stills_Photos_Images_10.jpg');
}
.container:first-child + .container + .container {
    background-image: url('http://www.moviehdwallpapers.com/wp-content/uploads/2014/10/happy_diwali__sms_images_.jpg');
}