JSFiddle - React, Tailwind, and code Playground

by rigor789

HTML

<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/bulma/0.3.1/css/bulma.css">
<div class="SettingsView">

  <div class="Header">
    <div class="level">
      <div class="level-left">
        <h2>Settings</h2>
      </div>
      <div class="level-right">
        <button class="delete"></button>
      </div>
    </div>
  </div>

  <div class="Content">
    <div class="level">
      <div class="level-left">
        <label for="#">Show Tray Icon</label>
      </div>
      <div class="level-right">
        <div class="switch switch--on"></div>
      </div>
    </div>

    <div class="level">
      <div class="level-left">
        <label for="#">Ignore whitespace</label>
      </div>
      <div class="level-right">
        <div class="switch switch--on"></div>
      </div>
    </div>

    <div class="level">
      <div class="level-left">
        <label for="#">Action when selecting</label>
      </div>
      <div class="level-right">

        <div class="select">
          <select>
            <option>Paste</option>
            <option>Copy</option>
          </select>
        </div>
      </div>
    </div>

    <div class="level">
      <div class="level-left">
        <label for="#">Max. history entries</label>
      </div>
      <div class="level-right">
        <input class="input" type="number" value="25">
      </div>
    </div>

    <div class="level">
      <div class="level-left">
        <label for="#">Enable window blacklist</label>
      </div>
      <div class="level-right">
        <div class="switch"></div>
      </div>
    </div>

    <div class="level">
      <div class="level-left">
        <label for="#">Blaclisted windows</label>
      </div>
      <div class="level-right">
        <input class="input" type="text" placeholder="comma separated list of window titles">
      </div>
    </div>
  </div>
</div>

CSS

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

.SettingsView {
  width: 550px;
  height: 350px;
  background: #222;
  color: #eee;
  font-family: sans-serif;
}

.Header {
  /*display: flex;*/
  /*align-items: center;*/
  height: 50px;
  box-shadow: 0 4px 2px -2px rgba(33, 33, 33, 0.3);
  position: relative;
  z-index: 1;
  background: #34495e;
  padding: 10px 15px;
}

.Header h2 {
  font-size: 20px;
}

.Content {
  padding: 15px;
  height: 300px;
  overflow: auto;
}

.Content label {
  display: block;
}

.switch {
  background: url('https://i.imgur.com/o4hfn8N.png');
  width: 38px;
  height: 24px;
}

.switch--on {
  background: url('https://i.imgur.com/4x483q2.png')
}

.select:after {
  border-color: #34495e;
}

.input:focus,
.input.is-focused,
.input:active,
.input.is-active,
.textarea:focus,
.textarea.is-focused,
.textarea:active,
.textarea.is-active {
  border-color: #34495e;
}


.level:not(:last-child) {
    margin-bottom: 1.2rem;
}