JSFiddle - React, Tailwind, and code Playground

by Ajsa Ferguson

HTML

<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.4/css/bootstrap.min.css">
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.4/js/bootstrap.min.js"></script>
<div class="container-fluid">
<article>
    <div id="post-1">
        <div class="row">
            <div class="col-sm-8 indx-img"></div>
            <div class="col-sm-4 text-cell">
                <h1>title</h1>
                <h3>category</h3>
                <p>Some text</p>
            </div>
        </div>
    </div>
</article>
</div>

CSS

.indx-img {
    padding: 16% 0;
    background-image: url('http://lorempixel.com/600/200/');
    background-size: cover;
}
.text-cell {
    background: #000;
    color: #FFF;
    overflow: auto;
}

JavaScript

(function () {
    "use strict";
    var resize = function () {
        var posts = document.querySelectorAll('[id^="post"] .row'), post;
        for (var i = 0; post = posts[i]; i++) {
            if (window.innerWidth > 768) {
                post.style.height = post.firstElementChild.offsetHeight + 'px';
                if(post.lastElementChild.style.height !== '100%') {
                    post.lastElementChild.style.height = '100%';
                }
            } else {
                if(post.style.height !== '')
                    post.style.height = '';
            }
        }
    };
    window.onresize = resize;
    resize();
})();