JSFiddle - React, Tailwind, and code Playground

by timshutes

HTML

<ul>
    <li>
        <img src="#">
        <div class="outer-wrapper">
            <div class="inner-wrapper">
            <h1>My Title</h1>
            <h5>Subtitle</h5>
            </div>
        </div>
    </li>
</ul>

CSS

html, body {
margin: 0; padding: 0;
width: 100%; height: 100%;
}

ul {
    background: #CCC;
    height: 100%;
    width: 100%;
    list-style-position: outside;
    margin: 0; padding: 0;
}

li {
    width: 100%;
    display: table;
}

img {
    width: 100%;
    height: 410px;
}

.outer-wrapper {
  position: absolute;
  width: 100%;
  height: 100%;
  top: 0;
  margin: 0; padding: 0;
}

.inner-wrapper {
  display: table-cell;
  vertical-align: middle;
  text-align: center;
  width: 100%;
  height: 100%;
}

h1 {
}